From: Ilia Alshanetsky Date: Sat, 12 Feb 2005 20:55:28 +0000 (+0000) Subject: Simplify code and fix compiler warning. X-Git-Tag: RELEASE_0_2_3~25 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9b394af973352aae4d6ca947425cba8e0ac96855;p=php Simplify code and fix compiler warning. --- diff --git a/ext/pdo_pgsql/pgsql_driver.c b/ext/pdo_pgsql/pgsql_driver.c index ca14b2c1b5..dc7da53afd 100644 --- a/ext/pdo_pgsql/pgsql_driver.c +++ b/ext/pdo_pgsql/pgsql_driver.c @@ -124,7 +124,6 @@ static int pgsql_handle_preparer(pdo_dbh_t *dbh, const char *sql, long sql_len, { pdo_pgsql_db_handle *H = (pdo_pgsql_db_handle *)dbh->driver_data; pdo_pgsql_stmt *S = ecalloc(1, sizeof(pdo_pgsql_stmt)); - int ret = 1; int scrollable; S->H = H; @@ -136,12 +135,10 @@ static int pgsql_handle_preparer(pdo_dbh_t *dbh, const char *sql, long sql_len, PDO_CURSOR_FWDONLY TSRMLS_CC) == PDO_CURSOR_SCROLL; if (scrollable) { - int ret = 1; - - spprintf(&S->cursor_name, 0, "pdo_pgsql_cursor_%08x", stmt); + spprintf(&S->cursor_name, 0, "pdo_pgsql_cursor_%08x", (unsigned int) stmt); } - return ret; + return 1; } static long pgsql_handle_doer(pdo_dbh_t *dbh, const char *sql, long sql_len TSRMLS_DC)