Skip to content

Commit ee5c807

Browse files
nobuhsbt
authored andcommitted
Adjust a fucntion signature
1 parent 3e98e4c commit ee5c807

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

ext/zlib/zlib.c

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4277,13 +4277,19 @@ rb_gzreader_external_encoding(VALUE self)
42774277
}
42784278

42794279
static VALUE
4280-
zlib_gzip_ensure(VALUE arg)
4280+
zlib_gzip_end_rescue(VALUE arg)
42814281
{
42824282
struct gzfile *gz = (struct gzfile *)arg;
4283-
rb_rescue((VALUE(*)())gz->end, arg, NULL, Qnil);
4283+
gz->end(gz);
42844284
return Qnil;
42854285
}
42864286

4287+
static VALUE
4288+
zlib_gzip_ensure(VALUE arg)
4289+
{
4290+
return rb_rescue(zlib_gzip_end_rescue, arg, NULL, Qnil);
4291+
}
4292+
42874293
static void
42884294
zlib_gzip_end(struct gzfile *gz)
42894295
{

0 commit comments

Comments
 (0)