diff options
author | Mark Spruiell <mes@zeroc.com> | 2006-11-07 19:17:06 +0000 |
---|---|---|
committer | Mark Spruiell <mes@zeroc.com> | 2006-11-07 19:17:06 +0000 |
commit | 5389b3eb490456cbfd80180ddf475f90f7478cec (patch) | |
tree | 7d64dc24747b20b81674f2747984d83fa8703465 /php/src | |
parent | Replace static Mutex by static StaticMutex (diff) | |
download | ice-5389b3eb490456cbfd80180ddf475f90f7478cec.tar.bz2 ice-5389b3eb490456cbfd80180ddf475f90f7478cec.tar.xz ice-5389b3eb490456cbfd80180ddf475f90f7478cec.zip |
fixing IceUtil::Options exceptions
Diffstat (limited to 'php/src')
-rw-r--r-- | php/src/ice/profile.cpp | 21 |
1 files changed, 15 insertions, 6 deletions
diff --git a/php/src/ice/profile.cpp b/php/src/ice/profile.cpp index 2bf9aae3ce7..37635e1ef27 100644 --- a/php/src/ice/profile.cpp +++ b/php/src/ice/profile.cpp @@ -322,10 +322,13 @@ parseSlice(const string& argStr, Slice::UnitPtr& unit TSRMLS_DC) { args = IceUtil::Options::split(argStr); } - catch(const IceUtil::Options::Error& ex) + catch(const IceUtil::Exception& ex) { + ostringstream ostr; + ex.ice_print(ostr); + string msg = ostr.str(); php_error_docref(NULL TSRMLS_CC, E_ERROR, "error occurred while parsing Slice options in `%s':\n%s", - argStr.c_str(), ex.reason.c_str()); + argStr.c_str(), msg.c_str()); return false; } @@ -348,10 +351,13 @@ parseSlice(const string& argStr, Slice::UnitPtr& unit TSRMLS_DC) return false; } } - catch(const IceUtil::Options::BadOpt& ex) + catch(const IceUtil::Exception& ex) { + ostringstream ostr; + ex.ice_print(ostr); + string msg = ostr.str(); php_error_docref(NULL TSRMLS_CC, E_ERROR, "error occurred while parsing Slice options in `%s':\n%s", - argStr.c_str(), ex.reason.c_str()); + argStr.c_str(), msg.c_str()); return false; } @@ -455,10 +461,13 @@ createProfile(const string& name, const string& config, const string& options, c { args = IceUtil::Options::split(options); } - catch(const IceUtil::Options::Error& ex) + catch(const IceUtil::Exception& ex) { + ostringstream ostr; + ex.ice_print(ostr); + string msg = ostr.str(); php_error_docref(NULL TSRMLS_CC, E_ERROR, "error occurred while parsing the options `%s':\n%s", - options.c_str(), ex.reason.c_str()); + options.c_str(), msg.c_str()); return false; } properties->parseCommandLineOptions("", args); |