about summary refs log tree commit homepage
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2016-12-29 06:43:49 +0000
committerEric Wong <e@80x24.org>2016-12-29 06:43:49 +0000
commit6f35eb68c0b45aa64da442022cda82b7df9194c4 (patch)
tree91a1f237f373efac52d6c5626da34f137c4b84ae
parentf8ebe8de94c9288caa1096f8fb02eed62a1b770d (diff)
downloadmogilefs-client-6f35eb68c0b45aa64da442022cda82b7df9194c4.tar.gz
We do not emit any sort of message on successful 2XX responses,
so there's no need to save the actual response after writing.
-rw-r--r--lib/mogilefs/new_file/common.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/mogilefs/new_file/common.rb b/lib/mogilefs/new_file/common.rb
index c102901..44eee69 100644
--- a/lib/mogilefs/new_file/common.rb
+++ b/lib/mogilefs/new_file/common.rb
@@ -23,7 +23,7 @@ module MogileFS::NewFile::Common
     start_time = @opts[:start_time] and tout -= MogileFS.now - start_time
     set_socket_options(sock)
     case line = sock.timed_read(23, "", tout > 0.0 ? tout : 0)
-    when %r{^HTTP/\d\.\d\s+(2\d\d)\s} # success!
+    when %r{^HTTP/\d\.\d\s+(?:2\d\d)\s} # success!
     when nil
       raise EmptyResponseError, 'Unable to read response line from server'
     when %r{^HTTP/\d\.\d\s+(\d+)}