mirror of
https://github.com/php/php-src.git
synced 2024-11-24 18:34:21 +08:00
initialize OCI in threaded mode if ZTS is defined.
This commit is contained in:
parent
9156c2c8d1
commit
74bc24d9d5
@ -376,10 +376,16 @@ PHP_MINIT_FUNCTION(oci)
|
||||
REGISTER_LONG_CONSTANT("OCI_D_LOB",OCI_DTYPE_LOB, CONST_CS | CONST_PERSISTENT);
|
||||
REGISTER_LONG_CONSTANT("OCI_D_ROWID",OCI_DTYPE_ROWID, CONST_CS | CONST_PERSISTENT);
|
||||
|
||||
#if OCI_USE_EMALLOC
|
||||
OCIInitialize(OCI_DEFAULT, NULL, ocimalloc, ocirealloc, ocifree);
|
||||
#ifdef ZTS
|
||||
#define PHP_OCI_INIT_MODE OCI_THREADED
|
||||
#else
|
||||
OCIInitialize(OCI_DEFAULT, NULL, NULL, NULL, NULL);
|
||||
#define PHP_OCI_INIT_MODE OCI_DEFAULT
|
||||
#endif
|
||||
|
||||
#if OCI_USE_EMALLOC
|
||||
OCIInitialize(PHP_OCI_INIT_MODE, NULL, ocimalloc, ocirealloc, ocifree);
|
||||
#else
|
||||
OCIInitialize(PHP_OCI_INIT_MODE, NULL, NULL, NULL, NULL);
|
||||
#endif
|
||||
|
||||
return SUCCESS;
|
||||
|
Loading…
Reference in New Issue
Block a user