From: Ilia Alshanetsky Date: Wed, 19 May 2004 20:38:25 +0000 (+0000) Subject: Timeout stuff. X-Git-Tag: RELEASE_0_1~92 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=676dfcf581b0d2b5a2b8cc3098bcac6321f6c9c7;p=php Timeout stuff. --- diff --git a/ext/pdo/pdo.c b/ext/pdo/pdo.c index 65d5c29c66..fa5a1dc6ca 100755 --- a/ext/pdo/pdo.c +++ b/ext/pdo/pdo.c @@ -213,7 +213,8 @@ PHP_MINIT_FUNCTION(pdo) REGISTER_LONG_CONSTANT("PDO_ATTR_AUTOCOMMIT", (long)PDO_ATTR_AUTOCOMMIT, CONST_CS|CONST_PERSISTENT); REGISTER_LONG_CONSTANT("PDO_ATTR_SCROLL", (long)PDO_ATTR_SCROLL, CONST_CS|CONST_PERSISTENT); - + REGISTER_LONG_CONSTANT("PDO_ATTR_TIMEOUT", (long)PDO_ATTR_TIMEOUT, CONST_CS|CONST_PERSISTENT); + INIT_CLASS_ENTRY(ce, "PDOException", NULL); pdo_exception_ce = zend_register_internal_class_ex(&ce, zend_exception_get_default(), NULL TSRMLS_CC); diff --git a/ext/pdo/php_pdo_driver.h b/ext/pdo/php_pdo_driver.h index a060436215..b1006d1f0c 100755 --- a/ext/pdo/php_pdo_driver.h +++ b/ext/pdo/php_pdo_driver.h @@ -58,6 +58,7 @@ enum pdo_attribute_type { PDO_ATTR_AUTOCOMMIT, /* use to turn on or off auto-commit mode */ PDO_ATTR_SCROLL, /* ask for a scrollable cursor (when you prepare()) */ PDO_ATTR_PREFETCH, /* configure the prefetch size for drivers that support it */ + PDO_ATTR_TIMEOUT, /* connection timeout in seconds */ }; /* generic error code values.