lib/rforce/binding.rb in aq1018-rforce-0.5.1 vs lib/rforce/binding.rb in aq1018-rforce-0.5.2
- old
+ new
@@ -237,12 +237,13 @@
# encode gzip
def encode(request)
return request if show_debug
begin
- ostream = StringIO.new
+ ostream = StringIO.new("", "w:BINARY")
gzw = Zlib::GzipWriter.new(ostream)
gzw.write(request)
+ gzw.flush
ostream.string
ensure
gzw.close
end
end