diff options
author | kwaclaw <kwaclaw> | 2006-04-14 17:53:03 +0000 |
---|---|---|
committer | kwaclaw <kwaclaw> | 2006-04-14 17:53:03 +0000 |
commit | 190ab47e161beb57267932ebf76bafa29150b05c (patch) | |
tree | 6bc06aab75e8726a0ce12b48a41bbd75f2fe217d | |
parent | f79358c4107a0126078001e129a9f457716a4a51 (diff) | |
download | libexpat-190ab47e161beb57267932ebf76bafa29150b05c.tar.gz |
Casting away some integer conversion warnings that should not pose a problem.
-rwxr-xr-x | xmlwf/xmlwf.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/xmlwf/xmlwf.c b/xmlwf/xmlwf.c index 2de9b92..1659b7b 100755 --- a/xmlwf/xmlwf.c +++ b/xmlwf/xmlwf.c @@ -129,7 +129,7 @@ startElement(void *userData, const XML_Char *name, const XML_Char **atts) p = atts; while (*p) ++p; - nAtts = (p - atts) >> 1; + nAtts = (int)((p - atts) >> 1); if (nAtts > 1) qsort((void *)atts, nAtts, sizeof(XML_Char *) * 2, attcmp); while (*atts) { @@ -189,7 +189,7 @@ startElementNS(void *userData, const XML_Char *name, const XML_Char **atts) p = atts; while (*p) ++p; - nAtts = (p - atts) >> 1; + nAtts = (int)((p - atts) >> 1); if (nAtts > 1) qsort((void *)atts, nAtts, sizeof(XML_Char *) * 2, nsattcmp); while (*atts) { @@ -350,7 +350,7 @@ metaStartElement(void *userData, const XML_Char *name, fputts(T(">\n"), fp); do { ftprintf(fp, T("<attribute name=\"%s\" value=\""), atts[0]); - characterData(fp, atts[1], tcslen(atts[1])); + characterData(fp, atts[1], (int)tcslen(atts[1])); if (atts >= specifiedAttsEnd) fputts(T("\" defaulted=\"yes\"/>\n"), fp); else if (atts == idAttPtr) @@ -381,7 +381,7 @@ metaProcessingInstruction(void *userData, const XML_Char *target, XML_Parser parser = (XML_Parser) userData; FILE *fp = (FILE *)XML_GetUserData(parser); ftprintf(fp, T("<pi target=\"%s\" data=\""), target); - characterData(fp, data, tcslen(data)); + characterData(fp, data, (int)tcslen(data)); puttc(T('"'), fp); metaLocation(parser); fputts(T("/>\n"), fp); @@ -393,7 +393,7 @@ metaComment(void *userData, const XML_Char *data) XML_Parser parser = (XML_Parser) userData; FILE *fp = (FILE *)XML_GetUserData(parser); fputts(T("<comment data=\""), fp); - characterData(fp, data, tcslen(data)); + characterData(fp, data, (int)tcslen(data)); puttc(T('"'), fp); metaLocation(parser); fputts(T("/>\n"), fp); @@ -469,7 +469,7 @@ metaNotationDecl(void *userData, ftprintf(fp, T(" public=\"%s\""), publicId); if (systemId) { fputts(T(" system=\""), fp); - characterData(fp, systemId, tcslen(systemId)); + characterData(fp, systemId, (int)tcslen(systemId)); puttc(T('"'), fp); } metaLocation(parser); @@ -503,7 +503,7 @@ metaEntityDecl(void *userData, if (publicId) ftprintf(fp, T(" public=\"%s\""), publicId); fputts(T(" system=\""), fp); - characterData(fp, systemId, tcslen(systemId)); + characterData(fp, systemId, (int)tcslen(systemId)); puttc(T('"'), fp); ftprintf(fp, T(" notation=\"%s\""), notationName); metaLocation(parser); @@ -514,7 +514,7 @@ metaEntityDecl(void *userData, if (publicId) ftprintf(fp, T(" public=\"%s\""), publicId); fputts(T(" system=\""), fp); - characterData(fp, systemId, tcslen(systemId)); + characterData(fp, systemId, (int)tcslen(systemId)); puttc(T('"'), fp); metaLocation(parser); fputts(T("/>\n"), fp); @@ -533,7 +533,7 @@ metaStartNamespaceDecl(void *userData, ftprintf(fp, T(" prefix=\"%s\""), prefix); if (uri) { fputts(T(" ns=\""), fp); - characterData(fp, uri, tcslen(uri)); + characterData(fp, uri, (int)tcslen(uri)); fputts(T("\"/>\n"), fp); } else @@ -576,7 +576,7 @@ unknownEncoding(void *userData, const XML_Char *name, XML_Encoding *info) if (!s) return 0; cp *= 10; - cp += s - digits; + cp += (int)(s - digits); if (cp >= 0x10000) return 0; } |