summaryrefslogtreecommitdiff
path: root/cpp/src/Slice/ObjCUtil.cpp
diff options
context:
space:
mode:
authorBenoit Foucher <benoit@zeroc.com>2015-01-21 14:09:00 +0100
committerBenoit Foucher <benoit@zeroc.com>2015-01-21 14:09:00 +0100
commit118ed1c4f6fc7195551b032ccfa9b9030afb72f5 (patch)
treefcc0ec89ed48be2b0b1f8757f2e581c639612e91 /cpp/src/Slice/ObjCUtil.cpp
parentUbuntu package cleanup (diff)
downloadice-118ed1c4f6fc7195551b032ccfa9b9030afb72f5.tar.bz2
ice-118ed1c4f6fc7195551b032ccfa9b9030afb72f5.tar.xz
ice-118ed1c4f6fc7195551b032ccfa9b9030afb72f5.zip
Fixed bug in Objective-C factory method name generation
Diffstat (limited to 'cpp/src/Slice/ObjCUtil.cpp')
-rw-r--r--cpp/src/Slice/ObjCUtil.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/cpp/src/Slice/ObjCUtil.cpp b/cpp/src/Slice/ObjCUtil.cpp
index a765081c06e..c4205f9a095 100644
--- a/cpp/src/Slice/ObjCUtil.cpp
+++ b/cpp/src/Slice/ObjCUtil.cpp
@@ -231,9 +231,9 @@ Slice::ObjCGenerator::getFactoryMethod(const ContainedPtr& p, bool deprecated)
}
else
{
- for(string::iterator p = name.begin(); p != name.end() - 1; ++p)
+ for(string::iterator p = name.begin(); p != name.end(); ++p)
{
- if(!isupper(*(p + 1)))
+ if(p != name.end() - 1 && !isupper(*(p + 1)))
{
break;
}