Menu

#87 Patch to prevent compiler warning when building for 64-bit

Feature Request
closed-out-of-date
nobody
patch (1)
5
2017-09-03
2013-09-29
calzakk
No

To avoid a compiler warning when building for 64-bit, could you change the XML_GetCurrentByteIndex function in xmlparse.c to the following (i.e. cast the subtraction):

XML_Index XMLCALL
XML_GetCurrentByteIndex(XML_Parser parser)
{
if (eventPtr)
return parseEndByteIndex - (XML_Index)(parseEndPtr - eventPtr);
return -1;
}

Discussion

  • Sebastian Pipping

    • status: open --> closed-out-of-date
     
  • Sebastian Pipping

    We have this code in by now:

    return (XML_Index)(parseEndByteIndex - (parseEndPtr - eventPtr));
    

    If you still get warnings, please open a new ticket or pull request at GitHub: https://github.com/libexpat/libexpat/issues/

     

Log in to post a comment.

MongoDB Logo MongoDB