From 3a1ebd4f519facbd7ec769304857aad40e49cf1c Mon Sep 17 00:00:00 2001 From: Harald Radi Date: Fri, 15 Mar 2002 20:48:26 +0000 Subject: [PATCH] @ fixed a bug that caused php to crash in php_COM_get_ids_of_names() (Harald, Paul) --- ext/com/COM.c | 2 ++ ext/rpc/com/com_wrapper.c | 2 ++ 2 files changed, 4 insertions(+) diff --git a/ext/com/COM.c b/ext/com/COM.c index 2e7dd0e1b73..854bd6be133 100644 --- a/ext/com/COM.c +++ b/ext/com/COM.c @@ -1172,6 +1172,7 @@ PHP_FUNCTION(com_propget) obj = (comval *)zend_list_find(Z_LVAL_P(arg_comval), &type); if (!obj || (type != IS_COM)) { php_error(E_WARNING,"%d is not a COM object handler", Z_LVAL_P(arg_comval)); + RETURN_FALSE; } convert_to_string_ex(&arg_property); @@ -1205,6 +1206,7 @@ PHP_FUNCTION(com_propput) obj = (comval *)zend_list_find(Z_LVAL_P(arg_comval), &type); if (!obj || (type != IS_COM)) { php_error(E_WARNING,"%d is not a COM object handler", Z_LVAL_P(arg_comval)); + RETURN_FALSE; } convert_to_string_ex(&arg_property); diff --git a/ext/rpc/com/com_wrapper.c b/ext/rpc/com/com_wrapper.c index 2e7dd0e1b73..854bd6be133 100644 --- a/ext/rpc/com/com_wrapper.c +++ b/ext/rpc/com/com_wrapper.c @@ -1172,6 +1172,7 @@ PHP_FUNCTION(com_propget) obj = (comval *)zend_list_find(Z_LVAL_P(arg_comval), &type); if (!obj || (type != IS_COM)) { php_error(E_WARNING,"%d is not a COM object handler", Z_LVAL_P(arg_comval)); + RETURN_FALSE; } convert_to_string_ex(&arg_property); @@ -1205,6 +1206,7 @@ PHP_FUNCTION(com_propput) obj = (comval *)zend_list_find(Z_LVAL_P(arg_comval), &type); if (!obj || (type != IS_COM)) { php_error(E_WARNING,"%d is not a COM object handler", Z_LVAL_P(arg_comval)); + RETURN_FALSE; } convert_to_string_ex(&arg_property);