diff options
author | John Peacock <jpeacock@rowman.com> | 2001-09-10 12:34:30 -0400 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2001-09-10 23:22:10 +0000 |
commit | e83d50c9254af4011034b5ec3368b06bb6254055 (patch) | |
tree | f63d3e504b549bff9f04218d6ba74a4a9e83e6ff /sv.c | |
parent | 12099e71b2695388375797515dbdfd0f741f2855 (diff) | |
download | perl-e83d50c9254af4011034b5ec3368b06bb6254055.tar.gz |
PATCH Resubmission - was Re: [ID 20010902.001] v strings over 2*31 barf
Message-ID: <3B9D23D6.90BCCC25@rowman.com>
p4raw-id: //depot/perl@11986
Diffstat (limited to 'sv.c')
-rw-r--r-- | sv.c | 27 |
1 files changed, 16 insertions, 11 deletions
@@ -7955,13 +7955,15 @@ Perl_sv_vcatpvfn(pTHX_ SV *sv, const char *pat, STRLEN patlen, va_list *args, SV if (!veclen) continue; if (vec_utf) - iv = (IV)utf8n_to_uvchr(vecstr, veclen, &ulen, 0); + uv = utf8n_to_uvchr(vecstr, veclen, &ulen, UTF8_ALLOW_ANYUV); else { - iv = *vecstr; + uv = *vecstr; ulen = 1; } vecstr += ulen; veclen -= ulen; + if (plus) + esignbuf[esignlen++] = plus; } else if (args) { switch (intsize) { @@ -7986,14 +7988,17 @@ Perl_sv_vcatpvfn(pTHX_ SV *sv, const char *pat, STRLEN patlen, va_list *args, SV #endif } } - if (iv >= 0) { - uv = iv; - if (plus) - esignbuf[esignlen++] = plus; - } - else { - uv = -iv; - esignbuf[esignlen++] = '-'; + if ( !vectorize ) /* we already set uv above */ + { + if (iv >= 0) { + uv = iv; + if (plus) + esignbuf[esignlen++] = plus; + } + else { + uv = -iv; + esignbuf[esignlen++] = '-'; + } } base = 10; goto integer; @@ -8035,7 +8040,7 @@ Perl_sv_vcatpvfn(pTHX_ SV *sv, const char *pat, STRLEN patlen, va_list *args, SV if (!veclen) continue; if (vec_utf) - uv = utf8n_to_uvchr(vecstr, veclen, &ulen, 0); + uv = utf8n_to_uvchr(vecstr, veclen, &ulen, UTF8_ALLOW_ANYUV); else { uv = *vecstr; ulen = 1; |