From: Gurusamy Sarathy Date: Tue, 7 Mar 2000 10:58:17 +0000 (+0000) Subject: avoid coredump on C X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=9c3dd3fe0ef5ca1dd7e835adfcf5e21c1099e72a;p=p5sagit%2Fp5-mst-13.2.git avoid coredump on C p4raw-id: //depot/perl@5596 --- diff --git a/sv.c b/sv.c index 8a86a92..f062bbb 100644 --- a/sv.c +++ b/sv.c @@ -5809,6 +5809,8 @@ Perl_sv_vcatpvfn(pTHX_ SV *sv, const char *pat, STRLEN patlen, va_list *args, SV vecsv = va_arg(*args, SV*); else if (svix < svmax) vecsv = svargs[svix++]; + else + continue; dotstr = SvPVx(vecsv,dotstrlen); if (DO_UTF8(vecsv)) is_utf = TRUE; @@ -5821,6 +5823,11 @@ Perl_sv_vcatpvfn(pTHX_ SV *sv, const char *pat, STRLEN patlen, va_list *args, SV vecsv = va_arg(*args, SV*); else if (svix < svmax) vecsv = svargs[svix++]; + else { + vecstr = ""; + veclen = 0; + continue; + } vecstr = (U8*)SvPVx(vecsv,veclen); utf = DO_UTF8(vecsv); continue;