Skip to content

Commit 34320bd

Browse files
authored
Merge pull request #85 from nobu/gcc-14
Tell gcc-14 that `Qnil` is not passed to `gzfile_calc_crc`
2 parents 3b45a5b + eb1cf42 commit 34320bd

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

ext/zlib/zlib.c

+2
Original file line numberDiff line numberDiff line change
@@ -4229,6 +4229,7 @@ gzreader_skip_linebreaks(struct gzfile *gz)
42294229
while (n++, *(p++) == '\n') {
42304230
if (n >= ZSTREAM_BUF_FILLED(&gz->z)) {
42314231
str = zstream_detach_buffer(&gz->z);
4232+
ASSUME(!NIL_P(str));
42324233
gzfile_calc_crc(gz, str);
42334234
while (ZSTREAM_BUF_FILLED(&gz->z) == 0) {
42344235
if (GZFILE_IS_FINISHED(gz)) return;
@@ -4637,6 +4638,7 @@ zlib_gunzip_run(VALUE arg)
46374638

46384639
gzfile_read_header(gz, Qnil);
46394640
dst = zstream_detach_buffer(&gz->z);
4641+
ASSUME(!NIL_P(dst));
46404642
gzfile_calc_crc(gz, dst);
46414643
if (!ZSTREAM_IS_FINISHED(&gz->z)) {
46424644
rb_raise(cGzError, "unexpected end of file");

0 commit comments

Comments
 (0)