Transactions commit on the last sqlite3_step(), not on sqlite3_finalize().
This allows the sqlite3_step() to return SQLITE_BUSY if the commit is
blocked by a lock.  Ticket #885. (CVS 1928)

FossilOrigin-Name: d1b29156558f1c576002cdb2544dffaa693da39b
diff --git a/src/main.c b/src/main.c
index af07d90..91dd1b2 100644
--- a/src/main.c
+++ b/src/main.c
@@ -14,7 +14,7 @@
 ** other files are for internal use by SQLite and should not be
 ** accessed by users of the library.
 **
-** $Id: main.c,v 1.256 2004/08/29 20:08:59 drh Exp $
+** $Id: main.c,v 1.257 2004/09/02 14:57:08 drh Exp $
 */
 #include "sqliteInt.h"
 #include "os.h"
@@ -521,7 +521,6 @@
     }
   }
   sqlite3ResetInternalSchema(db, 0);
-  /* sqlite3RollbackInternalChanges(db); */
 }
 
 /*
@@ -987,7 +986,7 @@
     ** Make a copy of that part of the SQL string since zSQL is const
     ** and we must pass a zero terminated string to the trace function
     ** The copy is unnecessary if the tail pointer is pointing at the
-    ** beginnig or end of the SQL string.
+    ** beginning or end of the SQL string.
     */
     if( sParse.zTail && sParse.zTail!=zSql && *sParse.zTail ){
       char *tmpSql = sqliteStrNDup(zSql, sParse.zTail - zSql);