summaryrefslogtreecommitdiff
path: root/php/src/php7/Util.cpp
diff options
context:
space:
mode:
authorJoe George <joe@zeroc.com>2016-05-31 15:58:29 -0400
committerJoe George <joe@zeroc.com>2016-05-31 15:58:29 -0400
commite40a438a70f06fb163020eb3b2cb42e0e18eb3ed (patch)
treebaff6d1b76f2a570fe01398d43fa0acf45e6ea3c /php/src/php7/Util.cpp
parentReworked description of wikipedia text (diff)
downloadice-e40a438a70f06fb163020eb3b2cb42e0e18eb3ed.tar.bz2
ice-e40a438a70f06fb163020eb3b2cb42e0e18eb3ed.tar.xz
ice-e40a438a70f06fb163020eb3b2cb42e0e18eb3ed.zip
Fix ICE-7163
- Printing types is more forgiving and will not throw an exception if there is bogus data. - Fix several print statements to print the correct class name.
Diffstat (limited to 'php/src/php7/Util.cpp')
-rw-r--r--php/src/php7/Util.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/php/src/php7/Util.cpp b/php/src/php7/Util.cpp
index 193f613f303..fa16d188475 100644
--- a/php/src/php7/Util.cpp
+++ b/php/src/php7/Util.cpp
@@ -80,7 +80,7 @@ getVersion(zval* zv, T& v, const char* type)
zend_class_entry* ce = Z_OBJCE_P(zv);
if(ce != cls)
{
- invalidArgument("expected an instance of %s", ce->name);
+ invalidArgument("expected an instance of %s", ce->name->val);
return false;
}
@@ -125,7 +125,7 @@ createVersion(zval* zv, const T& version, const char* type)
if(object_init_ex(zv, cls) != SUCCESS)
{
- runtimeError("unable to initialize %s", cls->name);
+ runtimeError("unable to initialize %s", cls->name->val);
return false;
}
@@ -255,7 +255,7 @@ IcePHP::extractIdentity(zval* zv, Ice::Identity& id)
zend_class_entry* ce = Z_OBJCE_P(zv);
if(ce != cls)
{
- invalidArgument("expected an identity but received %s", ce->name);
+ invalidArgument("expected an identity but received %s", ce->name->val);
return false;
}
@@ -595,7 +595,7 @@ IcePHP::convertException(zval* zex, const Ice::Exception& ex)
{
if(object_init_ex(zex, cls) != SUCCESS)
{
- runtimeError("unable to create exception %s", cls->name);
+ runtimeError("unable to create exception %s", cls->name->val);
return;
}
if(!convertLocalException(e, zex))
@@ -609,7 +609,7 @@ IcePHP::convertException(zval* zex, const Ice::Exception& ex)
assert(cls);
if(object_init_ex(zex, cls) != SUCCESS)
{
- runtimeError("unable to create exception %s", cls->name);
+ runtimeError("unable to create exception %s", cls->name->val);
return;
}
setStringMember(zex, "unknown", str);
@@ -621,7 +621,7 @@ IcePHP::convertException(zval* zex, const Ice::Exception& ex)
assert(cls);
if(object_init_ex(zex, cls) != SUCCESS)
{
- runtimeError("unable to create exception %s", cls->name);
+ runtimeError("unable to create exception %s", cls->name->val);
return;
}
setStringMember(zex, "unknown", str);
@@ -632,7 +632,7 @@ IcePHP::convertException(zval* zex, const Ice::Exception& ex)
assert(cls);
if(object_init_ex(zex, cls) != SUCCESS)
{
- runtimeError("unable to create exception %s", cls->name);
+ runtimeError("unable to create exception %s", cls->name->val);
return;
}
setStringMember(zex, "unknown", str);