summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAntony Dovgal <tony2001@php.net>2005-12-04 11:40:52 +0000
committerAntony Dovgal <tony2001@php.net>2005-12-04 11:40:52 +0000
commitc7631a2dca6c4ecac0c3e81faa7e5afffe179885 (patch)
treebbd9f7041ed58d768a6d58369909b714d103575e
parent7f8adfcc7e9843983990d1f6bff85b5c91cd0c15 (diff)
downloadphp-git-c7631a2dca6c4ecac0c3e81faa7e5afffe179885.tar.gz
fix #35543 (php crash when calling non existing method of a class that extends PDO)
-rwxr-xr-xext/pdo/pdo_dbh.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/pdo/pdo_dbh.c b/ext/pdo/pdo_dbh.c
index 6d98af2b5b..96a6047d6c 100755
--- a/ext/pdo/pdo_dbh.c
+++ b/ext/pdo/pdo_dbh.c
@@ -1110,7 +1110,7 @@ int pdo_hash_methods(pdo_dbh_t *dbh, int kind TSRMLS_DC)
int namelen;
char *lc_name;
- if (!dbh->methods->get_driver_methods) {
+ if (!dbh || !dbh->methods || !dbh->methods->get_driver_methods) {
return 0;
}
funcs = dbh->methods->get_driver_methods(dbh,