summaryrefslogtreecommitdiff
path: root/cpp
diff options
context:
space:
mode:
authorMichi Henning <michi@zeroc.com>2004-12-08 02:54:29 +0000
committerMichi Henning <michi@zeroc.com>2004-12-08 02:54:29 +0000
commit1f7df37892b323a4bfd1803fbc596e6acd1e7169 (patch)
treef89f34c15ceacdb43c0b3050c38f1ea22bca4691 /cpp
parentRemoved some trace I left behind. (diff)
downloadice-1f7df37892b323a4bfd1803fbc596e6acd1e7169.tar.bz2
ice-1f7df37892b323a4bfd1803fbc596e6acd1e7169.tar.xz
ice-1f7df37892b323a4bfd1803fbc596e6acd1e7169.zip
Fixed bug in parsing for --Ice.Config: previous code dereferenced an
invalidated STL iterator.
Diffstat (limited to 'cpp')
-rw-r--r--cpp/src/Ice/PropertiesI.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/cpp/src/Ice/PropertiesI.cpp b/cpp/src/Ice/PropertiesI.cpp
index 2042b518239..6be3ce9d9a3 100644
--- a/cpp/src/Ice/PropertiesI.cpp
+++ b/cpp/src/Ice/PropertiesI.cpp
@@ -265,6 +265,7 @@ Ice::PropertiesI::PropertiesI(StringSeq& args)
{
setProperty("Ice.ProgramName", *q);
}
+ StringSeq tmp;
while(q != args.end())
{
string s = *q;
@@ -275,13 +276,14 @@ Ice::PropertiesI::PropertiesI(StringSeq& args)
s += "=1";
}
parseLine(s.substr(2));
- args.erase(q);
}
else
{
- ++q;
+ tmp.push_back(s);
}
+ ++q;
}
+ args = tmp;
loadConfig();