diff options
author | Nicholas Clark <nick@ccl4.org> | 2002-10-27 18:39:03 +0000 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2002-10-28 20:46:33 +0000 |
commit | e568f1a0c324be00c66a63ff9480ccd16934f37e (patch) | |
tree | a68f9329a34d450ab1e53882c5dc691f503efdec /util.c | |
parent | 92b5f8d10a61fa2f07cadd651b15112c54e27db5 (diff) | |
download | perl-e568f1a0c324be00c66a63ff9480ccd16934f37e.tar.gz |
Re: Not OK: perl v5.9.0 +DEVEL17881 on i386-freebsd 4.6-release (UNINSTALLED)
Message-ID: <20021027183902.GJ292@Bagpuss.unfortu.net>
p4raw-id: //depot/perl@18070
Diffstat (limited to 'util.c')
-rw-r--r-- | util.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -3704,6 +3704,7 @@ is a beta version). char * Perl_scan_version(pTHX_ char *s, SV *rv) { + const char *start = s; char *pos = s; I32 saw_period = 0; bool saw_under = 0; @@ -3743,7 +3744,7 @@ Perl_scan_version(pTHX_ char *s, SV *rv) /* this is atoi() that delimits on underscores */ char *end = pos; I32 mult = 1; - if ( s < pos && *(s-1) == '_' ) { + if ( s < pos && s > start && *(s-1) == '_' ) { if ( *s == '0' && *(s+1) != '0') mult = 10; /* perl-style */ else |