Ticket #92 (closed defect: fixed)
MarkupSTL.cpp - always true comparison
| Reported by: | mloskot | Owned by: | |
|---|---|---|---|
| Priority: | major | Milestone: | 3.2.0 |
| Component: | tests | Version: | 2.2.2 |
| Severity: | Content | Keywords: | imported,phpbugtracker |
| Cc: |
Description (last modified by mloskot) (diff)
g++ with -pedantic option reports following warning that may significantly influence logic of this code:
/home/mloskot/dev/geos/_cvs/geos/tests/xmltester/markup/MarkupSTL.cpp:884: warning: comparison is always true due to limited range of data type
Here is this comparison:
int nEndCDATA = m_strDoc.find( "]]>",
token.nNext );
if ( (unsigned int)nEndCDATA != string::npos
&& nEndCDATA < m_aPos[iPos].nEndL )
{
return m_strDoc.substr(token.nL+9,
nEndCDATA-token.nL-9 );
}
Attachments
Change History
Note: See
TracTickets for help on using
tickets.

