projects
/
platform
/
upstream
/
perl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
37ca3c2
)
Re: [perl #32687] Encode::is_utf8 on tainted UTF8 string
author
Rafael Garcia-Suarez
<rgarciasuarez@gmail.com>
Thu, 16 Nov 2006 17:36:44 +0000
(18:36 +0100)
committer
Rafael Garcia-Suarez
<rgarciasuarez@gmail.com>
Thu, 22 Mar 2007 18:26:36 +0000
(18:26 +0000)
Message-ID: <
20061116173644
.
4412f66f
@grubert.mandriva.com>
p4raw-id: //depot/perl@30693
ext/Encode/Encode.xs
patch
|
blob
|
history
diff --git
a/ext/Encode/Encode.xs
b/ext/Encode/Encode.xs
index
895819b
..
ba2bf62
100644
(file)
--- a/
ext/Encode/Encode.xs
+++ b/
ext/Encode/Encode.xs
@@
-757,15
+757,11
@@
CODE:
{
if (SvGMAGICAL(sv)) /* it could be $1, for example */
sv = newSVsv(sv); /* GMAGIG will be done */
- if (SvPOK(sv)) {
RETVAL = SvUTF8(sv) ? TRUE : FALSE;
if (RETVAL &&
check &&
!is_utf8_string((U8*)SvPVX(sv), SvCUR(sv)))
RETVAL = FALSE;
- } else {
- RETVAL = FALSE;
- }
if (sv != ST(0))
SvREFCNT_dec(sv); /* it was a temp copy */
}