[pypy-commit] pypy default: slightly more correct, may matter in obscure or future cases

bdkearns noreply at buildbot.pypy.org
Wed Apr 3 23:09:19 CEST 2013


Author: Brian Kearns <bdkearns at gmail.com>
Branch: 
Changeset: r62991:fa9fd512a0bb
Date: 2013-04-03 17:08 -0400
http://bitbucket.org/pypy/pypy/changeset/fa9fd512a0bb/

Log:	slightly more correct, may matter in obscure or future cases

diff --git a/lib_pypy/_sqlite3.py b/lib_pypy/_sqlite3.py
--- a/lib_pypy/_sqlite3.py
+++ b/lib_pypy/_sqlite3.py
@@ -145,6 +145,7 @@
     const char **pzTail     /* OUT: Pointer to unused portion of zSql */
 );
 int sqlite3_finalize(sqlite3_stmt *pStmt);
+int sqlite3_data_count(sqlite3_stmt *pStmt);
 int sqlite3_column_count(sqlite3_stmt *pStmt);
 const char *sqlite3_column_name(sqlite3_stmt*, int N);
 int sqlite3_get_autocommit(sqlite3*);
@@ -1222,7 +1223,7 @@
 
     def _readahead(self, cursor):
         row = []
-        num_cols = _lib.sqlite3_column_count(self._statement)
+        num_cols = _lib.sqlite3_data_count(self._statement)
         for i in xrange(num_cols):
             if self.__con._detect_types:
                 converter = self.__row_cast_map[i]


More information about the pypy-commit mailing list