From 7f33ab834d87452082526205c256a4827fb71142 Mon Sep 17 00:00:00 2001 From: Anatol Belski Date: Sun, 18 Oct 2015 11:14:30 +0200 Subject: [PATCH] C89 compat --- ext/pdo_dblib/dblib_stmt.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/ext/pdo_dblib/dblib_stmt.c b/ext/pdo_dblib/dblib_stmt.c index 0b519995ca..d6c2c703d5 100644 --- a/ext/pdo_dblib/dblib_stmt.c +++ b/ext/pdo_dblib/dblib_stmt.c @@ -197,14 +197,15 @@ static int pdo_dblib_stmt_describe(pdo_stmt_t *stmt, int colno TSRMLS_DC) { pdo_dblib_stmt *S = (pdo_dblib_stmt*)stmt->driver_data; pdo_dblib_db_handle *H = S->H; + struct pdo_column_data *col; + char *fname; if(colno >= stmt->column_count || colno < 0) { return FAILURE; } - struct pdo_column_data *col = &stmt->columns[colno]; - - char *fname = (char*)dbcolname(H->link, colno+1); + col = &stmt->columns[colno]; + fname = (char*)dbcolname(H->link, colno+1); if (fname && *fname) { col->name = estrdup(fname); -- 2.40.0