diff options
author | Anatol Belski <ab@php.net> | 2014-08-19 08:07:31 +0200 |
---|---|---|
committer | Anatol Belski <ab@php.net> | 2014-08-19 08:07:31 +0200 |
commit | 63d3f0b844b3a5f1c94be3c97bca29235dc2b3fc (patch) | |
tree | e561a58d6e084c5e4cbdde1f84aed16cf4724383 /ext/pdo_dblib | |
parent | 1e8273964fbd517a2eb9e560f9cdb4afffa0c034 (diff) | |
download | php-git-63d3f0b844b3a5f1c94be3c97bca29235dc2b3fc.tar.gz |
basic macro replacements, all at once
Diffstat (limited to 'ext/pdo_dblib')
-rw-r--r-- | ext/pdo_dblib/dblib_driver.c | 6 | ||||
-rw-r--r-- | ext/pdo_dblib/dblib_stmt.c | 10 |
2 files changed, 8 insertions, 8 deletions
diff --git a/ext/pdo_dblib/dblib_driver.c b/ext/pdo_dblib/dblib_driver.c index 350a3c670d..67a3241a66 100644 --- a/ext/pdo_dblib/dblib_driver.c +++ b/ext/pdo_dblib/dblib_driver.c @@ -60,12 +60,12 @@ static int dblib_fetch_error(pdo_dbh_t *dbh, pdo_stmt_t *stmt, zval *info TSRMLS spprintf(&message, 0, "%s [%d] (severity %d) [%s]", msg, einfo->dberr, einfo->severity, stmt ? stmt->active_query_string : ""); - add_next_index_long(info, einfo->dberr); + add_next_index_int(info, einfo->dberr); // TODO: avoid reallocation ??? add_next_index_string(info, message); efree(message); - add_next_index_long(info, einfo->oserr); - add_next_index_long(info, einfo->severity); + add_next_index_int(info, einfo->oserr); + add_next_index_int(info, einfo->severity); if (einfo->oserrstr) { add_next_index_string(info, einfo->oserrstr); } diff --git a/ext/pdo_dblib/dblib_stmt.c b/ext/pdo_dblib/dblib_stmt.c index c13d58bd57..fd0999f7e4 100644 --- a/ext/pdo_dblib/dblib_stmt.c +++ b/ext/pdo_dblib/dblib_stmt.c @@ -303,13 +303,13 @@ static int pdo_dblib_stmt_get_column_meta(pdo_stmt_t *stmt, long colno, zval *re if(!dbtypeinfo) return FAILURE; - add_assoc_long(return_value, "max_length", dbcollen(H->link, colno+1) ); - add_assoc_long(return_value, "precision", (int) dbtypeinfo->precision ); - add_assoc_long(return_value, "scale", (int) dbtypeinfo->scale ); + add_assoc_int(return_value, "max_length", dbcollen(H->link, colno+1) ); + add_assoc_int(return_value, "precision", (int) dbtypeinfo->precision ); + add_assoc_int(return_value, "scale", (int) dbtypeinfo->scale ); add_assoc_string(return_value, "column_source", dbcolsource(H->link, colno+1)); add_assoc_string(return_value, "native_type", pdo_dblib_get_field_name(dbcoltype(H->link, colno+1))); - add_assoc_long(return_value, "native_type_id", dbcoltype(H->link, colno+1)); - add_assoc_long(return_value, "native_usertype_id", dbcolutype(H->link, colno+1)); + add_assoc_int(return_value, "native_type_id", dbcoltype(H->link, colno+1)); + add_assoc_int(return_value, "native_usertype_id", dbcolutype(H->link, colno+1)); return 1; } |