From: Rafael Garcia-Suarez Date: Fri, 10 Jun 2005 12:07:01 +0000 (+0000) Subject: SvUPGRADE returns void in blead X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=f2e5e56948e20feccc483331db17d10a7d20863d;p=p5sagit%2Fp5-mst-13.2.git SvUPGRADE returns void in blead p4raw-id: //depot/perl@24787 --- diff --git a/ext/Compress/Zlib/Zlib.xs b/ext/Compress/Zlib/Zlib.xs index 2421f2c..a9f6297 100644 --- a/ext/Compress/Zlib/Zlib.xs +++ b/ext/Compress/Zlib/Zlib.xs @@ -422,8 +422,7 @@ Zip_gzread(file, buf, len=4096) CODE: if (SvREADONLY(buf) && PL_curcop != &PL_compiling) croak("gzread: buffer parameter is read-only"); - if (!SvUPGRADE(buf, SVt_PV)) - croak("cannot use buf argument as lvalue"); + SvUPGRADE(buf, SVt_PV); SvPOK_only(buf); SvCUR_set(buf, 0); /* any left over from gzreadline ? */ @@ -468,8 +467,7 @@ gzreadline(file, buf) CODE: if (SvREADONLY(buf) && PL_curcop != &PL_compiling) croak("gzreadline: buffer parameter is read-only"); - if (!SvUPGRADE(buf, SVt_PV)) - croak("cannot use buf argument as lvalue"); + SvUPGRADE(buf, SVt_PV); SvPOK_only(buf); /* sv_setpvn(buf, "", SIZE) ; */ SvGROW(buf, SIZE) ;