]> granicus.if.org Git - php/commitdiff
Fix ASSERT logic
authorKeyur <kgovande@etsy.com>
Tue, 9 Aug 2016 14:41:20 +0000 (14:41 +0000)
committerKeyur <kgovande@etsy.com>
Tue, 9 Aug 2016 18:16:58 +0000 (18:16 +0000)
ext/pdo/pdo_dbh.c

index 461c65471bae638caadbf709d31c43fd79311fa1..4411c681bded68a6177ef69094dbd3c9733c010f 100644 (file)
@@ -1508,7 +1508,7 @@ static void dbh_free(pdo_dbh_t *dbh, zend_bool free_persistent)
 
        if (dbh->is_persistent) {
 #if ZEND_DEBUG
-               ZEND_ASSERT(free_persistent && (dbh->refcount == 1));
+               ZEND_ASSERT(!free_persistent || (dbh->refcount == 1));
 #endif
                if (!free_persistent && (--dbh->refcount)) {
                        return;