summaryrefslogtreecommitdiff
path: root/ext/pdo_oci/oci_driver.c
diff options
context:
space:
mode:
authorGeorge Peter Banyard <girgias@php.net>2020-12-23 15:02:50 +0100
committerGeorge Peter Banyard <girgias@php.net>2021-01-06 10:21:06 +0000
commit954d3743cce0390f4435cf118d20b84a7320a836 (patch)
tree890dd11ddae1a23b66182ae6ddb4b593de897afa /ext/pdo_oci/oci_driver.c
parent43f69160cfac8e33969e059eeab756a223be4480 (diff)
downloadphp-git-954d3743cce0390f4435cf118d20b84a7320a836.tar.gz
Boolify PDO's quoter handler
Diffstat (limited to 'ext/pdo_oci/oci_driver.c')
-rw-r--r--ext/pdo_oci/oci_driver.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/ext/pdo_oci/oci_driver.c b/ext/pdo_oci/oci_driver.c
index b104a38333..af3d6b7539 100644
--- a/ext/pdo_oci/oci_driver.c
+++ b/ext/pdo_oci/oci_driver.c
@@ -354,7 +354,7 @@ static zend_long oci_handle_doer(pdo_dbh_t *dbh, const char *sql, size_t sql_len
}
/* }}} */
-static int oci_handle_quoter(pdo_dbh_t *dbh, const char *unquoted, size_t unquotedlen, char **quoted, size_t *quotedlen, enum pdo_param_type paramtype ) /* {{{ */
+static bool oci_handle_quoter(pdo_dbh_t *dbh, const char *unquoted, size_t unquotedlen, char **quoted, size_t *quotedlen, enum pdo_param_type paramtype ) /* {{{ */
{
int qcount = 0;
char const *cu, *l, *r;
@@ -364,7 +364,7 @@ static int oci_handle_quoter(pdo_dbh_t *dbh, const char *unquoted, size_t unquot
*quotedlen = 2;
*quoted = emalloc(*quotedlen+1);
strcpy(*quoted, "''");
- return 1;
+ return true;
}
/* count single quotes */
@@ -387,7 +387,7 @@ static int oci_handle_quoter(pdo_dbh_t *dbh, const char *unquoted, size_t unquot
(*quoted)[*quotedlen-1] = '\'';
(*quoted)[*quotedlen] = '\0';
- return 1;
+ return true;
}
/* }}} */