diff options
author | Jose <jose@zeroc.com> | 2019-06-21 22:22:14 +0200 |
---|---|---|
committer | Jose <jose@zeroc.com> | 2019-06-21 22:22:14 +0200 |
commit | d1b7c66fab777fe72e5cf77fd284218e2080b017 (patch) | |
tree | b48615b2d9d2f59195c8a560e07585b9cbb77cb5 /cpp/src/Ice/Initialize.cpp | |
parent | Add ice_isFixed - Close #356 (diff) | |
download | ice-d1b7c66fab777fe72e5cf77fd284218e2080b017.tar.bz2 ice-d1b7c66fab777fe72e5cf77fd284218e2080b017.tar.xz ice-d1b7c66fab777fe72e5cf77fd284218e2080b017.zip |
Enable -Wconversion with clang - Close #363
Diffstat (limited to 'cpp/src/Ice/Initialize.cpp')
-rw-r--r-- | cpp/src/Ice/Initialize.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/cpp/src/Ice/Initialize.cpp b/cpp/src/Ice/Initialize.cpp index 70f48b781ac..1dfd7290b8f 100644 --- a/cpp/src/Ice/Initialize.cpp +++ b/cpp/src/Ice/Initialize.cpp @@ -570,11 +570,12 @@ Ice::stringToIdentity(const string& s) // Find unescaped separator; note that the string may contain an escaped // backslash before the separator. // - string::size_type slash = string::npos, pos = 0; + string::size_type slash = string::npos; + string::size_type pos = 0; while((pos = s.find('/', pos)) != string::npos) { - int escapes = 0; - while(static_cast<int>(pos) - escapes > 0 && s[pos - escapes - 1] == '\\') + string::size_type escapes = 0; + while(static_cast<int>(pos - escapes) > 0 && s[pos - escapes - 1] == '\\') { escapes++; } |