summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorarseny.kapoulkine@gmail.com <arseny.kapoulkine@gmail.com@99668b35-9821-0410-8761-19e4c4f06640>2013-11-26 04:34:41 +0000
committerarseny.kapoulkine@gmail.com <arseny.kapoulkine@gmail.com@99668b35-9821-0410-8761-19e4c4f06640>2013-11-26 04:34:41 +0000
commit79109a8546f963d17522d75112cffcfd8cbe35fc (patch)
treec4133de7a4d1335575aff86440e1a50bc203fc7a /src
parent48600c3a9d30e0762eb2956dd50789705eef3f69 (diff)
Fix gcc-4.8 compilation warning when using -Wstrict-overflow
git-svn-id: http://pugixml.googlecode.com/svn/trunk@956 99668b35-9821-0410-8761-19e4c4f06640
Diffstat (limited to 'src')
-rw-r--r--src/pugixml.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/pugixml.cpp b/src/pugixml.cpp
index 29fbd8a..b13a4d5 100644
--- a/src/pugixml.cpp
+++ b/src/pugixml.cpp
@@ -1681,7 +1681,7 @@ PUGI__NS_BEGIN
for (;;)
{
- if (static_cast<unsigned int>(ch - '0') <= 9)
+ if (static_cast<unsigned int>(static_cast<unsigned int>(ch) - '0') <= 9)
ucsc = 10 * ucsc + (ch - '0');
else if (ch == ';')
break;
@@ -6436,7 +6436,7 @@ PUGI__NS_BEGIN
{
while (exponent > 0)
{
- assert(*mantissa == 0 || static_cast<unsigned int>(*mantissa - '0') <= 9);
+ assert(*mantissa == 0 || static_cast<unsigned int>(static_cast<unsigned int>(*mantissa) - '0') <= 9);
*s++ = *mantissa ? *mantissa++ : '0';
exponent--;
}