summaryrefslogtreecommitdiff
path: root/ext/sqlite3/sqlite3.c
diff options
context:
space:
mode:
authorScott MacVicar <scottmac@php.net>2011-01-06 00:08:59 (GMT)
committerScott MacVicar <scottmac@php.net>2011-01-06 00:08:59 (GMT)
commitef0a793fdda747f1764c06718aacb5500f67b28f (patch)
tree6b4278a5491d48c4807a82ce9f7556666918fabe /ext/sqlite3/sqlite3.c
parent78728e33fa197d67ce8ddd652c5e0510db85af0f (diff)
downloadphp-ef0a793fdda747f1764c06718aacb5500f67b28f.tar.gz
Implemented FR #53466 (SQLite3Result::columnType() should return false after all of the rows have been fetched).
Diffstat (limited to 'ext/sqlite3/sqlite3.c')
-rw-r--r--ext/sqlite3/sqlite3.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/ext/sqlite3/sqlite3.c b/ext/sqlite3/sqlite3.c
index d3d92aa..cc33112 100644
--- a/ext/sqlite3/sqlite3.c
+++ b/ext/sqlite3/sqlite3.c
@@ -1582,6 +1582,10 @@ PHP_METHOD(sqlite3result, columnType)
return;
}
+ if (result_obj->complete) {
+ RETURN_FALSE;
+ }
+
RETURN_LONG(sqlite3_column_type(result_obj->stmt_obj->stmt, column));
}
/* }}} */
@@ -1631,6 +1635,7 @@ PHP_METHOD(sqlite3result, fetchArray)
break;
case SQLITE_DONE:
+ result_obj->complete = 1;
RETURN_FALSE;
break;