You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@xerces.apache.org by "Alberto Massari (JIRA)" <xe...@xml.apache.org> on 2005/01/12 14:08:17 UTC
[jira] Resolved: (XERCESC-628) passing -1 to unsigned parameter
[ http://issues.apache.org/jira/browse/XERCESC-628?page=history ]
Alberto Massari resolved XERCESC-628:
-------------------------------------
Assign To: (was: Xerces-C Developers Mailing List)
Resolution: Fixed
The bug should have been fixed by the general cleanup of warning messages.
Please verify.
Alberto
> passing -1 to unsigned parameter
> --------------------------------
>
> Key: XERCESC-628
> URL: http://issues.apache.org/jira/browse/XERCESC-628
> Project: Xerces-C++
> Type: Bug
> Components: Build
> Versions: 2.1.0
> Environment: Operating System: Other
> Platform: Other
> Reporter: gareth reakes
> Attachments: bug12851.patch
>
> This is in the cvs tree.
> XMLScanner.cpp: In method `bool XMLScanner::scanStartTag (bool &)':
> XMLScanner.cpp:2977: warning: passing negative value `-1' for argument
> 1 of `XMLAttr::XMLAttr (unsigned int, const XMLCh *, const XMLCh *,
> const XMLCh *, XMLAttDef::AttTypes, bool)'
> XMLScanner.cpp:2990: warning: passing negative value `-1' for argument
> 1 of `XMLAttr::set (unsigned int, const XMLCh *, const XMLCh *, const
> XMLCh *, XMLAttDef::AttTypes)'
> XMLScanner.cpp:3113: warning: passing negative value `-1' for argument
> 1 of `XMLAttr::XMLAttr (unsigned int, const XMLCh *, const XMLCh *,
> const XMLCh *, XMLAttDef::AttTypes, bool)'
> XMLScanner.cpp:3127: warning: passing negative value `-1' for argument
> 1 of `XMLAttr::set (unsigned int, const XMLCh *, const XMLCh *, const
> XMLCh *, XMLAttDef::AttTypes)'
> I have had a look at the code and I think changing these to 0 is OK. I have
> attached a patch that does this. If someone thinks that 0 is no good then please
> say :)
> patch:
> Index: XMLScanner.cpp
> ===================================================================
> RCS file: /home/cvspublic/xml-xerces/c/src/xercesc/internal/XMLScanner.cpp,v
> retrieving revision 1.21
> diff -u -r1.21 XMLScanner.cpp
> --- XMLScanner.cpp 16 Sep 2002 20:37:33 -0000 1.21
> +++ XMLScanner.cpp 20 Sep 2002 10:12:32 -0000
> @@ -2968,7 +2968,7 @@
> {
> curAtt = new XMLAttr
> (
> - -1
> + 0
> , fAttNameBuf.getRawBuffer()
> , XMLUni::fgZeroLenString
> , fAttValueBuf.getRawBuffer()
> @@ -2982,7 +2982,7 @@
> curAtt = fAttrList->elementAt(attCount);
> curAtt->set
> (
> - -1
> + 0
> , fAttNameBuf.getRawBuffer()
> , XMLUni::fgZeroLenString
> , fAttValueBuf.getRawBuffer()
> @@ -3104,7 +3104,7 @@
> {
> curAtt = new XMLAttr
> (
> - -1
> + 0
> , curDef.getFullName()
> , XMLUni::fgZeroLenString
> , curDef.getValue()
> @@ -3119,7 +3119,7 @@
> curAtt = fAttrList->elementAt(attCount);
> curAtt->set
> (
> - -1
> + 0
> , curDef.getFullName()
> , XMLUni::fgZeroLenString
> , curDef.getValue()
> @@ -4557,4 +4557,4 @@
> void XMLScanner::resetCachedGrammarPool()
> {
> fGrammarResolver->resetCachedGrammar();
> -}
> \ No newline at end of file
> +}
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-c-dev-help@xml.apache.org