summaryrefslogtreecommitdiff
path: root/ext/Encode
diff options
context:
space:
mode:
authorRobin Barker <RMBarker@cpan.org>2002-05-09 19:27:30 +0100
committerJarkko Hietaniemi <jhi@iki.fi>2002-05-10 03:38:40 +0000
commit436c6dd385a3b29cadf4fa091af1c55eed665e29 (patch)
treec47c2a42bc0de462dbee66b55ada5cd11bca25cf /ext/Encode
parent810d9308ad3234b6d649cdfae5bbe4bf70e41ce7 (diff)
downloadperl-436c6dd385a3b29cadf4fa091af1c55eed665e29.tar.gz
format and other warnings
Message-Id: <200205091727.SAA22792@tempest.npl.co.uk> p4raw-id: //depot/perl@16532
Diffstat (limited to 'ext/Encode')
-rw-r--r--ext/Encode/Encode.xs6
-rw-r--r--ext/Encode/Unicode/Unicode.xs2
2 files changed, 4 insertions, 4 deletions
diff --git a/ext/Encode/Encode.xs b/ext/Encode/Encode.xs
index 0f3f1d4185..09918a1785 100644
--- a/ext/Encode/Encode.xs
+++ b/ext/Encode/Encode.xs
@@ -80,7 +80,7 @@ encode_method(pTHX_ encode_t * enc, encpage_t * dir, SV * src,
goto ENCODE_END;
}
- while (code = do_encode(dir, s, &slen, d, dlen, &dlen, !check))
+ while( (code = do_encode(dir, s, &slen, d, dlen, &dlen, !check)) )
{
SvCUR_set(dst, dlen+ddone);
SvPOK_only(dst);
@@ -172,14 +172,14 @@ encode_method(pTHX_ encode_t * enc, encpage_t * dir, SV * src,
else {
if (check & ENCODE_DIE_ON_ERR){
Perl_croak(aTHX_ ERR_DECODE_NOMAP,
- PTR2UV(enc->name[0]), (U8)s[slen]);
+ enc->name[0], (UV)s[slen]);
return &PL_sv_undef; /* never reaches but be safe */
}
if (check & ENCODE_WARN_ON_ERR){
Perl_warner(
aTHX_ packWARN(WARN_UTF8),
ERR_DECODE_NOMAP,
- PTR2UV(enc->name[0]), (U8)s[slen]);
+ enc->name[0], (UV)s[slen]);
}
if (check & ENCODE_RETURN_ON_ERR){
goto ENCODE_SET_SRC;
diff --git a/ext/Encode/Unicode/Unicode.xs b/ext/Encode/Unicode/Unicode.xs
index e3ad82c7f0..a330ea07f5 100644
--- a/ext/Encode/Unicode/Unicode.xs
+++ b/ext/Encode/Unicode/Unicode.xs
@@ -212,7 +212,7 @@ CODE:
if (!issurrogate(ord)){
if (ucs2) {
if (check) {
- croak("%s:code point \"\\x{"UVxf"}\" too high",
+ croak("%s:code point \"\\x{%"UVxf"}\" too high",
SvPV_nolen(
*hv_fetch((HV *)SvRV(obj),"Name",4,0))
,ord);