aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authordanielk1977 <danielk1977@noemail.net>2007-07-12 13:18:05 +0000
committerdanielk1977 <danielk1977@noemail.net>2007-07-12 13:18:05 +0000
commit612642de320b8d2591cf40c95c6735ff81f4c1e6 (patch)
treed5ed4d74f835cf26d18adb5949f81c65580f7b3f /src
parentd8e9b6238ebb95e925691af8fa1b7896cc969b50 (diff)
downloadsqlite-612642de320b8d2591cf40c95c6735ff81f4c1e6.tar.gz
sqlite-612642de320b8d2591cf40c95c6735ff81f4c1e6.zip
Fix for #2497. Set the database error code to the return value of sqlite3_step(). (CVS 4155)
FossilOrigin-Name: b01fda5f50e40b6122faf169c44486bde7ffe16c
Diffstat (limited to 'src')
-rw-r--r--src/vdbeapi.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/vdbeapi.c b/src/vdbeapi.c
index 1db9513bb..49c6f9288 100644
--- a/src/vdbeapi.c
+++ b/src/vdbeapi.c
@@ -275,6 +275,7 @@ end_of_step:
if( p->zSql && (rc&0xff)<SQLITE_ROW ){
/* This behavior occurs if sqlite3_prepare_v2() was used to build
** the prepared statement. Return error codes directly */
+ sqlite3Error(p->db, p->rc, 0);
return p->rc;
}else{
/* This is for legacy sqlite3_prepare() builds and when the code