2002-03-14  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.5.1 released.

2002-03-14  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (gzfile_read_header): flush input buffer after reading header.
	Thanks to HARUYAMA Seigo <haruyama@queen-ml.org>.

2002-03-14  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.rd.src: typo fixed.

2002-03-14  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.5.0 released.

2002-03-14  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* depend: added $(srcdir).

2002-03-14  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c: use EXTERN instead of extern.

2002-03-12  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (gzwriter_defout_ensure, gzwriter_call_defout, CALL_DEFOUT):
	added.

	* zlib.c (rb_gzwriter_print): set myself to rb_defout and call
	Kernel::print instead of copying codes from io.c.
	(rb_gzwriter_puts): ditto.

2002-03-12  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* extconf.rb: added have_ruby_func().

	* extconf.rb: added checks for rb_io_print, rb_io_printf, rb_io_puts
	and rb_io_addstr.

	* zlib.c (rb_gzwriter_addstr): use rb_io_addstr if it is extern.
	(rb_gzwriter_print): ditto.
	(rb_gzwriter_printf): ditto.
	(rb_gzwriter_puts): ditto.

2002-02-11  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* makerd.rb: tiny bugfix.

	* zlib.rd.src: reviced Zlib, ZStream, Deflate and Inflate.

2002-02-06  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.5.0-pre6 released.

2002-02-04  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (Init_zlib): remove method Zlib::Error#next_in.

	* zlib.c (raise_zlib_error): Zlib::Error doesn't keep next_in any more.
	The stream preserves next_in and next_out whether an error occurs.

	* zlib.c (ZSTREAM_IS_FINALIZE): new macro.

2002-02-04  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (zstream_append_buffer2,zstream_append_input2): new macro.

2002-02-04  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (Init_zlib): new method Zlib::ZStream#stream_end? and
	Zlib::ZStream#ended?.

	* zlib.rd.src: add descriptions for above two methods.

2002-02-04  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (rb_deflate_deprecated): call super.
	(rb_inflate_deprecated): ditto.
	(rb_gzwriter_deprecated): ditto.
	(rb_gzreader_deprecated): ditto.

	* zlib.c (Init_zlib): warning message is printed when Deflate.deflate
	and Inflate.inflate is used.

	* zlib.c (zstream_end): keep both buffers whether the stream is
	finished.
	(rb_zstream_flush_next_in): works well regardless of the status of the
	stream.
	(rb_zstream_flush_next_out): ditto.
	(rb_zstream_avail_out): ditto.
	(rb_zstream_avail_in): ditto.

2002-02-04  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (zstream_run2): removed.
	(do_deflate,do_inflate): derived from zstream_run2().
	(rb_deflate_deflate): use do_deflate() instead of zstream_run2().
	(rb_deflate_addstr): ditto.
	(rb_inflate_inflate): use do_inflate() instead of zstream_run2().
	(rb_inflate_addstr): ditto.

	* zlib.c (zstream_run_loop,zstream_run): integrated into zstream_run().

	* zlib.c (rb_deflate_s_deflate): Zlib::Deflate.deflate doesn't
	accept nil.
	(rb_inflate_s_inflate): Zlib::Inflate.inflate, neither.

2002-02-01  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (rb_deflate_flush): doesn't call zstream_run() if
	flush == Z_NO_FLUSH.
	(rb_gzwriter_flush): ditto.

	* zlib.rd.src: appended description for Zlib::ZStream#finish.

2002-02-01  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (zstream_run_loop): zero-length check should be done
	before calling zstream_run().
	(gzfile_write): ditto.
	(gzfile_read_more): ditto.

	* zlib.c (rb_gzwriter_write): calls gzfile_write() even if len == 0.

	* zlib.c (gzfile_read_more): ZSTREAM_IS_FINISHED() should be true
	without calling zstream_run() when gzfile_read_raw() returns nil.

2002-02-01  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (zstream_sync,rb_infalte_sync): new method Inflate#sync.

	* zlib.rd.src: added description for Inflate#sync.

	* zlib.c (rb_deflate_flush): bugfix.

2002-02-01  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (rb_zlib_cannot_allocate,Init_zlib): Zlib::ZStream and
	Zlib::GzipFile are abstract classes; they must not allocate their
	instances.

2002-02-01  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.5.0-pre5 released.

2002-02-01  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (zstream_run_loop): doesn't start compressing/decompressing
	loop if	flush is set to Z_NO_FLUSH and the input is an empty string.

	* zlib.c (zstream_run_loop): rewrote.

	* zlib.c (zstream_append_input): doesn't make buffer if len == 0.

	* zlib.c (zstream_run2): when flush == Z_FINISH, next_in should be
	non-NULL even if avail_in == 0. Otherwise, Z_STREAM_ERROR may be
	caused.
	(rb_zstream_finish): ditto.
	(rb_deflate_flush): ditto.
	(rb_inflate_s_inflate): ditto.
	(gzfile_writer_end): ditto.
	(rb_gzwriter_flush): ditto.

	* zlib.c (ZSTREAM_AVAIL_OUT_MIN): renamed ZSTREAM_AVAIL_OUT_MIN to
	ZSTREAM_AVAIL_OUT_STEP_MIN.
	* zlib.c (ZSTREAM_AVAIL_OUT_STEP): renamed ZSTREAM_AVAIL_OUT_STEP to
	ZSTREAM_AVAIL_OUT_STEP_MAX.
	(ZSTREAM_AVAIL_OUT_STEP_MIN): set to 2048.
	(ZSTREAM_AVAIL_OUT_STEP_MAX): set to 16384.

	* zlib.c (zstream_detach_input): added.
	(rb_zstream_flush_next_in,Init_zlib): new method ZStream#flush_next_in.

	* rzlib.rd.src: add descriptions for new methods.

2002-01-31  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (zstream_expand_buffer_into): added.
	(rb_zstream_avail_out): new method ZStream#avail_out.
	(rb_zstream_set_avail_out): new method ZStream#avail_out=.
	(rb_zstream_avail_in): new method ZStream#avail_in.
	(Init_zlib): define above new methods.

	* zlib.c (zstream_init): next_in and avail_in should be initialized.

	* zlib.c (zlib_mem_alloc,zlib_mem_free,zstream_init): use Ruby's
	memory allocation for zalloc and zfree.

	* zlib.c (Init_zlib): added constant Zlib::FINISH and Zlib::VERSION.
	(zstream_init):

	* zlib.rd.src: added description for Zlib::FINISH and Zlib::VERSION.

	* extconf.rb: '<<' was missed.

	* zlib.c (do_checksum): called checksum function twice when
	no argument is given to Zlib.crc32 or Zlib.adler32.

	* zlib.c (rb_zlib_str_value): StringValue() caused segv with
	Ruby-1.6 if argument is nil.

	* zlib.c (zstream_run_loop): if flush == Z_FINISH, the loop
	must be continued until z->func->run returns Z_STREAM_END.

2002-01-29  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (gzfile_reader_get_unused): gz->z.input may be nil.

2002-01-29  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.5.0-pre4 released.

2002-01-29  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (Init_zlib): Zlib::Deflate.new and Zlib::Inflate.new are
	integrated into Zlib::ZStream.new.

	* zlib.rd.src: added description for Zlib::ZStream.new.

2002-01-28  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c: adapt to ruby-1.7.

	* zlib.c: redefine macros for backward compatibility.

	* zlib.c (Init_zlib): added allocate methods.
	(rb_deflate_s_allocate): ditto.
	(rb_inflate_s_allocate): ditto.
	(rb_gzwriter_s_allocate): ditto.
	(rb_gzreader_s_allocate): ditto.

	* zlib.c (rb_gzwriter_s_new,rb_gzreader_s_new): removed and
	integreted into rb_gzfile_s_new.

	* zlib.c (rb_zlib_version): return value of Zlib.version should be
	tainted.

	* extconf.rb: changed check for rb_str_buf_new.

	* zlib.rd.src: added description for Zlib::GzipFile.new.

2002-01-09  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.5.0-pre3 released.

2002-01-08  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c: added some macros for ruby-1.7 from Nobuyoshi Nakada's
	patch ([ruby-ext:02048]). But they are disabled by #if 0.

	* zlib.c: defined macro RB_ZLIB_NORETRURN.

	* zlib.c, extconf.rb: NO_BLOCK_GIVEN_P -> !HAVE_BLOCK_GIVEN_P.
	RUBY_NEW_NORETURN -> HAVE_NEW_NORETURN.

	* zlib.rd.src: put untranslated parts into English.

	* zlib.c (gzfile_ensure_close): close gzfile directly instead of
	calling close method.

2002-01-07  WATANABE Hirofumi <eban@os.rim.or.jp>

	* extconf.rb: cygwin is not a Win32.

2002-01-07  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* extconf.rb: add dir_config("zlib").

2002-01-06  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.5.0-pre2 released.

2002-01-06  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (gzfile_writer_end): protect gzfile_write_raw() at finalize.

	* zlib.c (gzfile_ensure_close): close method must be sent to obj
	itself, not gz->io.

	* extconf.rb: added msg_check.

	* extconf.rb: define "NO_BLOCK_GIVEN_P" instead of "rb_block_given_p"
	if block_given? doesn't exist.

	* zlib.c: stop using RUBY_VERSION_CODE.

2002-01-06  Nobuyoshi Nakada  <nobu.nakada@nifty.ne.jp>

	* extconf.rb: added checks for Ruby-1.7.

2002-01-06  Tanaka Akira  <akr@m17n.org>

	* zlib.rd.src: modified.

2002-01-06  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.rd.src: modified.

2002-01-06  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.5.0-pre1 released.

2002-01-06  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.rd.src: rewrote the document by RD.

	* makerd.rb: added script to generate language-separated RD.

	* depend: added dependencies for documents.

2002-01-05  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* extconf.rb: check CONFIG['target_os'], not CONFIG['host_os'].

	* zlib.c: added member `input' to struct zstream.
	(zstream_append_input): added for expandable input buffer.
	(zstream_discard_input): ditto.
	(zstream_reset_input): ditto.
	(zstream_passthrough_input): ditto.
	(zstream_run,zstream_run_loop): divided the inflate/deflate loop from
	zstream_run to zstream_run_loop and added consideration for NeedDict.

	* zlib.c (raize_zlib_error): added the third parameter `next_in'.
	(rb_zerror_next_in): added Zlib::ZError#next_in.

	* zlib.c: removed member `unused' from struct gzfile.
	(gzfile_reader_get_unused): GzipReader#unused returns nil if
	the GzipReader object is closed.

	* zlib.c (Init_zlib): GzipReader and GzipWriter class are deprecated;
	use Zlib::GzipReader and Zlib::GzipWriter.
	(Init_zlib): Zlib::GzipReader::OS_* -> Zlib::OS_*
	(Init_Zlib): Zlib::GzipReader::{NoFooter,CRCError,LengthError} ->
	Zlib::GzipFile::*

	* zlib.c: add ZSTREAM_FLAG_FINALIZE to prevent segv in finalizer.

	* zlib.c (gzfile_writer_end): warn Zlib::GzipWriter object must be
	closed explicitly.

	* zlib.c (rb_zstream_flush_out): rename to rb_zstream_flush_next_out.
	(Init_zlib): rename ZStream#flush_out to ZStream#flush_next_out.

	* zlib.c (rb_zerror_initialize): added Zlib::Error#initialize.

2002-01-02  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c: rename `flag' in struct zstream to `flags'.

	* zlib.c: reformat and rearrenge the code.

	* zlib.c: refactor functions and macros for zstream and gzfile.
	Since these are very core funcs, the whole of zlib.c is
	almostly rewrote. No changes must be found in behaviors
	of any classes and modules, I hope.

	* zlib.c: use OBJ_INFECT instead of if(OBJ_TAINTED)OBJ_TAINT.

	* zlib.c (rb_deflate_clone): call CLONESETUP.

	* zlib.c: removed sanity checks for arguments for deflateInit2
	and inflateInit2.
	(value_to_compression_level): removed.
	(value_to_window_bits): ditto.
	(value_to_memlevel): ditto.
	(value_to_strategy): ditto.
	(value_to_flush): ditto.

	* zlib.c (rb_deflate_s_new,rb_deflate_initialize): only do allocation
	in Deflate::new and initializing in Deflate#initialize.
	(rb_inflate_s_new,rb_inflate_initialize): ditto.

	* zlib.c (Init_zlib): Deflate and Inflate class are deprecated;
	use Zlib::Deflate and Zlib::Inflate.
	(rb_deflate_deprecated,rb_inflate_deprecated): added for
	warning this is a deprecated class.

	* zlib.c (Init_zlib): constants defined under Deflate and Inflate are
	moved under Zlib.

	* zlib.c (rb_gzwriter_puts): adapt to ruby-1.7.

	* zlib.c (Init_zlib): rename Zlib::Gzip to Zlib::GzipFile.

2002-01-01  UENO Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c: make all functions static.

	* zlib.c: update copyright line.

	* THANKS: added.

2001-09-15  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (zstream_shift_buffer): bug fixed about buffer overflow.
	  Thanks to Ned Konz <ned@bike-nomad.com>.

2000-09-26  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.4.0 released.

2000-09-26  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (gzip_safe_close): doesn't check gzip footer.
	(rb_gzip_eof_p): GzipReader#eof? returns true if GzipReader object
	reaches the end of compressed data, not the end of file.

2000-09-20  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c: adapted to ruby-1.6.0.

2000-07-20  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.3.1 released.

2000-07-20  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (zstream_run_internal): properly support for Z_SYNC_FLUSH
	and Z_FULL_FLUSH.

2000-07-20  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.3.0 released.

2000-07-20  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (zstream_run_internal): always accepts an empty string.
	Deflate#deflate with an empty string now works correctly.
	(rb_gzipwriter_write): remove string size check before zstream_run().

	* zlib.c (rb_deflate_flush): added Deflate#flush.
	(rb_gzipwriter_flush): added GzipWriter#flush.
	(rb_gzipwriter_write, rb_gzipwriter_putc): FULL_FLUSH -> SYNC_FLUSH

	* zlib.ja.html, zlib.en.html: updated.

2000-07-19  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.2.2 released.

2000-07-19  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (rb_gzipwriter_s_open): bug fixed. A gzip file must be
	opened in binary mode.

2000-07-17  Lewis Perin  <perin@panix.com>

	* zlib.c (rb_gzipreader_s_open): bug fixed. A gzip file must be
	opened in binary mode.

2000-07-15  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.2.1 released.

2000-07-15  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (gzip_close, gzipreader_close, gzip_safe_close): added
	gzip_close() and gzip_safe_close(), and renamed a few functions.
	(gzipwriter_new, rb_gzipreader_s_new): Gzip{Writer|Reader}::{new|open}
	accept a block, just like File::open.

	* zlib.c (GZFILE_ZSTREAM_FINISHED, GZFILE_EOF): added.
	(gzipreader_close, rb_gzip_unused): bug fixed about small gzip file.

	* zlib.ja.html, zlib.en.html: updated.

	* extconf.rb: added the attention message about OS_CODE.

2000-06-29  Yasushi Shoji  <yasushi_shoji@necam.ny.nec.com>

	* zlib.en.html: proofread.

2000-06-26  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.2.0a released.

2000-06-25  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.en.html: proofreaded by SUGIHARA Hiroshi <maili31s@clio.ne.jp>.

2000-06-24  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.2.0 released.

2000-06-24  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.html, zlib.ja.html: renamed zlib.html to zlib.ja.html
	* zlib.en.html: added.

2000-06-22  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (rb_{deflate|inflate}_addstr): both Deflate#<< and Inflate#<<
	methods return the object itself.
	(rb_zstream_flush_out): added ZStream#flush_out method.

2000-06-20  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.1.2 released.

2000-06-20  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (gzip_mark): forgot to call zstream_mark().

2000-06-19  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (zstream_expand_buffer): expands buffer at least
	ZSTERAM_AVAIL_OUT_MIN bytes.

2000-06-18  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.1.1 released.

2000-06-18  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (gzipwriter_close): write .gz header if it is not written yet.

	* zlib.c (gzip_close,gzipwriter_close): bug fixed.

2000-06-16  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.1.0 released.

2000-06-15  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* gzip.rb, zlib.c: rewrote Gzip* classes in C.

	* zlib.html: updated.

2000-06-14  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c: cError -> cZError
	(struct zstream): buf_total_out -> buf_filled
	(zstream_make_buffer, zstream_expand_buffer): cleanups.
	(zstream_shift_buffer): return String object.
	(zstream_buffer_concat,zstream_append_buffer):
	renamed zstream_buffer_concat() to zstream_append_buffer().

2000-05-31  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (zstream_expand_buffer,zstream_run):
	keep other threads from stopping during deflating/inflating.

	* zlib.c (zstream_shift_buffer): added.
	(rb_gzip_inflate_inflate): use zstream_shift_buffer() instead
	of memmove().

2000-05-31  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.0.2 released.

	* extconf.rb: guess OS_CODE before create_makefile.

2000-05-30  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* gzip.rb (Gzip#write_header): improved.
	(GzipReader#getc): prevented overrunning.
	(GzipReader#readlines): implemented properly.

	* zlib.html: proofread.

2000-05-29  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.0.1 released.

2000-05-29  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (rb_zstream_finished_p): added ZStream#finished?
	(rb_zstream_closed_p): added ZStream#closed?

	* zlib.c, gzip.rb: instant support for .gz files
	* extconf.rb: guess OS_CODE

2000-05-28  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c (Init_zlib,zstream_new,zstream_clone):
	undefined ZStream::new and removed ZStream#clone
	(Init_zlib): added some constants to Deflate and Inflate
	(Init_zlib,rb_inflate_sync_point_p): added Inflate#sync_point?

	* zlib.html: updated.

2000-05-25  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* zlib.c: cleanups.

2000-05-23  Ueno Katsuhiro  <katsu@blue.sky.or.jp>

	* version 0.0 released.
