Skip to content

Commit

Permalink
Correct comment in zlib.h on os setting in gzip header.
Browse files Browse the repository at this point in the history
The comment said that the os is set to 255, when in fact it has
been set to the current os since zlib 1.2.3. Or at least our best
guess at the os made at compile time.
  • Loading branch information
madler committed May 17, 2023
1 parent 48c3741 commit 263a982
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions zlib.h
Original file line number Diff line number Diff line change
Expand Up @@ -821,8 +821,9 @@ ZEXTERN int ZEXPORT deflateSetHeader(z_streamp strm,
gzip file" and give up.
If deflateSetHeader is not used, the default gzip header has text false,
the time set to zero, and os set to 255, with no extra, name, or comment
fields. The gzip header is returned to the default state by deflateReset().
the time set to zero, and os set to the current operating system, with no
extra, name, or comment fields. The gzip header is returned to the default
state by deflateReset().
deflateSetHeader returns Z_OK if success, or Z_STREAM_ERROR if the source
stream state was inconsistent.
Expand Down

0 comments on commit 263a982

Please sign in to comment.