Issue #8467 has been reported by vicente.mundim (Vicente Mundim).

----------------------------------------
Bug #8467: Rewinding and iterating through gzipped IO leads to segmentation fault
https://bugs.ruby-lang.org/issues/8467

Author: vicente.mundim (Vicente Mundim)
Status: Open
Priority: Normal
Assignee: 
Category: lib
Target version: 
ruby -v: ruby 2.0.0p195 (2013-05-14 revision 40734) [x86_64-darwin12.3.0]
Backport: 1.9.3: UNKNOWN, 2.0.0: UNKNOWN


The following steps reproduce the bug in 2.0.0:

- Create a file and gzip it in a terminal:

    echo "some content" > compressed_file && gzip compressed_file

Then start a IRB session with the following code:

>> require 'zlib'
>> filename = "compressed_file.gz"
>> io = Zlib::GzipReader.new(open(filename, 'rb'))
>> io.rewind
>> io.each {} # segmentation_fault in Ruby 2.0.0

This works in Ruby 1.9.3, 1.9.2, and 1.8.7.


-- 
http://bugs.ruby-lang.org/