Hi, On Mon, 8 Oct 2001 21:27:52 +0900 Tobias Reif <tobiasreif / pinkjuice.com> wrote: > How can I make the following work? > I try to gzip a string, then unzip it: You must finish the deflate stream if you want the whole of compressed data. Try the following code: require 'zlib' initial_string = "Tobi\n" defl = Deflate.new infl = Inflate.new deflated = defl.deflate(initial_string) + defl.finish print deflated restored_string = infl.inflate(deflated) print restored_string or simply; deflated = Deflate.deflate(initial_string) -- ---- - - - -- - UENO Katsuhiro <unnie / blue.sky.or.jp>