diff options
Diffstat (limited to 'ext/dbx/dbx_oci8.c')
| -rw-r--r-- | ext/dbx/dbx_oci8.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ext/dbx/dbx_oci8.c b/ext/dbx/dbx_oci8.c index da50844334..bc69ee4553 100644 --- a/ext/dbx/dbx_oci8.c +++ b/ext/dbx/dbx_oci8.c @@ -276,6 +276,10 @@ int dbx_oci8_esc(zval **rv, zval **dbx_handle, zval **string, INTERNAL_FUNCTION_ char * tmpstr; int tmplen; + if (Z_STRLEN_PP(string) == 0) { + ZVAL_EMPTY_STRING(*rv); + return 1; + } tmpstr = estrdup(Z_STRVAL_PP(string)); tmplen = Z_STRLEN_PP(string); /* php_str_to_str uses a smart_str that allocates memory */ |
