diff options
author | H.Merijn Brand <h.m.brand@xs4all.nl> | 2005-06-15 13:57:57 +0000 |
---|---|---|
committer | H.Merijn Brand <h.m.brand@xs4all.nl> | 2005-06-15 13:57:57 +0000 |
commit | 97972285a7cc3296dc99230fa10f7a030afa733f (patch) | |
tree | 7fe203266c0d1c19d11af92c15a9de655daec9a2 /sv.c | |
parent | 39c9c9cd8e3664420b75ceafcc0d146575e756e4 (diff) | |
download | perl-97972285a7cc3296dc99230fa10f7a030afa733f.tar.gz |
Protect Perl_sv_2pvbyte () to NULL length pointers
Thanks Nick!
p4raw-id: //depot/perl@24850
Diffstat (limited to 'sv.c')
-rw-r--r-- | sv.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -3775,7 +3775,7 @@ char * Perl_sv_2pvbyte(pTHX_ register SV *sv, STRLEN *lp) { sv_utf8_downgrade(sv,0); - return SvPV(sv,*lp); + return lp ? SvPV(sv,*lp) : SvPV_nolen(sv); } /* |