]> granicus.if.org Git - php/commitdiff
Passed db_handle to dbx_error_function instead of NULL (Mc)
authorMarc Boeren <mboeren@php.net>
Mon, 7 May 2001 14:49:05 +0000 (14:49 +0000)
committerMarc Boeren <mboeren@php.net>
Mon, 7 May 2001 14:49:05 +0000 (14:49 +0000)
# I don't know why it worked on my machine, but now it works
# because the code is right, not through magic :)

ext/dbx/dbx.c

index 8762e6cf60cfe208f4fc048d5046710161e3681a..662433aedc4e16c33f4a73b33a60aabec7d98ad9 100644 (file)
@@ -64,7 +64,6 @@ int get_module_identifier(char * module_name) {
     return DBX_UNKNOWN;
     }
 
-
 int split_dbx_handle_object(zval ** dbx_object, zval *** pdbx_handle, zval *** pdbx_module, zval *** pdbx_database) {
     convert_to_object_ex(dbx_object);
     if (zend_hash_find((*dbx_object)->value.obj.properties, "handle", 7, (void **) pdbx_handle)==FAILURE
@@ -509,7 +508,7 @@ ZEND_FUNCTION(dbx_error)
 
     MAKE_STD_ZVAL(rv_errormsg); 
     ZVAL_LONG(rv_errormsg, 0);
-    result = switch_dbx_error(&rv_errormsg, NULL, INTERNAL_FUNCTION_PARAM_PASSTHRU, dbx_module);
+    result = switch_dbx_error(&rv_errormsg, dbx_handle, INTERNAL_FUNCTION_PARAM_PASSTHRU, dbx_module);
     if (!result) {
         FREE_ZVAL(rv_errormsg);
         RETURN_STRING("", 1);