ruby-core@ruby-lang.org archive (unofficial mirror)
 help / color / mirror / Atom feed
From: exaspark@gmail.com
To: ruby-core@ruby-lang.org
Subject: [ruby-core:69362] [Ruby trunk - Bug #9790] Zlib::GzipReader only decompressed the first of concatenated files
Date: Tue, 26 May 2015 09:37:54 +0000	[thread overview]
Message-ID: <redmine.journal-52636.20150526093753.76f0e8a4f96fc332@ruby-lang.org> (raw)
In-Reply-To: redmine.issue-9790.20140430205653@ruby-lang.org

Issue #9790 has been updated by Evgeny Li.


Hey guys, is there any updates?

I have created a small gem yesterday to make it able to read multiple files https://github.com/exAspArk/multiple_files_gzip_reader

~~~ruby
> MultipleFilesGzipReader.open("3.txt.gz") do |gz|
>   puts gz.read
> end

# 1
# 2
# => nil
~~~

----------------------------------------
Bug #9790: Zlib::GzipReader only decompressed the first of concatenated files
https://bugs.ruby-lang.org/issues/9790#change-52636

* Author: Jake Quain
* Status: Assigned
* Priority: Normal
* Assignee: Eric Hodel
* ruby -v: 2.1.1
* Backport: 2.0.0: UNKNOWN, 2.1: UNKNOWN
----------------------------------------
There is a similar old issue in Node that I came across that perfectly describes the situation in ruby:

https://github.com/joyent/node/issues/6032

In ruby given the following setup:

```
echo "1" > 1.txt
echo "2" > 2.txt
gzip 1.txt
gzip 2.txt
cat 1.txt.gz 2.txt.gz > 3.txt.gz
```

Calling:
    
```
Zlib::GzipReader.open("3.txt.gz") do |gz|
  print gz.read
end
```

would just print:

```
1
```




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

  parent reply	other threads:[~2015-05-26  9:20 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <redmine.issue-9790.20140430205653@ruby-lang.org>
2014-04-30 20:56 ` [ruby-core:62257] [ruby-trunk - Bug #9790] [Open] Zlib::GzipReader only decompressed the first of concatenated files quainjn
2014-05-01 22:53 ` [ruby-core:62271] [ruby-trunk - Bug #9790] [Assigned] " drbrain
2015-02-24 16:17 ` [ruby-core:68286] [Ruby trunk - Bug #9790] " akostadinov
2015-02-25  6:16 ` [ruby-core:68303] " duerst
2015-05-26  9:37 ` exaspark [this message]
2019-11-27 15:38 ` [ruby-core:95987] [Ruby master Bug#9790] " merch-redmine
2020-01-14  4:10 ` [ruby-core:96832] " ko1
2020-01-14  4:33 ` [ruby-core:96833] " merch-redmine
2020-01-16  7:39 ` [ruby-core:96898] " ko1
2020-01-16 14:32 ` [ruby-core:96910] " daniel
2020-01-17  4:51 ` [ruby-core:96922] " shyouhei
2020-01-17 14:17 ` [ruby-core:96927] " daniel
2020-01-17 16:04 ` [ruby-core:96929] " merch-redmine
2020-01-18  0:51 ` [ruby-core:96933] " nobu
2020-01-18  1:07 ` [ruby-core:96934] " merch-redmine

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.ruby-lang.org/en/community/mailing-lists/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=redmine.journal-52636.20150526093753.76f0e8a4f96fc332@ruby-lang.org \
    --to=ruby-core@ruby-lang.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).