Loading core/java/android/database/sqlite/SQLiteCompiledSql.java +7 −3 Original line number Diff line number Diff line Loading @@ -49,7 +49,7 @@ import android.util.Log; /** the following are for debugging purposes */ private String mSqlStmt = null; private Throwable mStackTrace = null; private final Throwable mStackTrace; /** when in cache and is in use, this member is set */ private boolean mInUse = false; Loading @@ -59,7 +59,11 @@ import android.util.Log; db.verifyLockOwner(); mDatabase = db; mSqlStmt = sql; if (StrictMode.vmSqliteObjectLeaksEnabled()) { mStackTrace = new DatabaseObjectNotClosedException().fillInStackTrace(); } else { mStackTrace = null; } nHandle = db.mNativeHandle; native_compile(sql); } Loading Loading @@ -112,7 +116,7 @@ import android.util.Log; // but if the database itself is not closed and is GC'ed, then // all sub-objects attached to the database could end up getting GC'ed too. // in that case, don't print any warning. if (mInUse && StrictMode.vmSqliteObjectLeaksEnabled()) { if (mInUse && mStackTrace != null) { int len = mSqlStmt.length(); StrictMode.onSqliteObjectLeaked( "Releasing statement in a finalizer. Please ensure " + Loading core/java/android/database/sqlite/SQLiteCursor.java +6 −2 Original line number Diff line number Diff line Loading @@ -95,7 +95,11 @@ public class SQLiteCursor extends AbstractWindowedCursor { if (query.mDatabase == null) { throw new IllegalArgumentException("query.mDatabase cannot be null"); } if (StrictMode.vmSqliteObjectLeaksEnabled()) { mStackTrace = new DatabaseObjectNotClosedException().fillInStackTrace(); } else { mStackTrace = null; } mDriver = driver; mEditTable = editTable; mColumnNameMap = null; Loading Loading @@ -319,7 +323,7 @@ public class SQLiteCursor extends AbstractWindowedCursor { try { // if the cursor hasn't been closed yet, close it first if (mWindow != null) { if (StrictMode.vmSqliteObjectLeaksEnabled()) { if (mStackTrace != null) { int len = mQuery.mSql.length(); StrictMode.onSqliteObjectLeaked( "Finalizing a Cursor that has not been deactivated or closed. " + Loading Loading
core/java/android/database/sqlite/SQLiteCompiledSql.java +7 −3 Original line number Diff line number Diff line Loading @@ -49,7 +49,7 @@ import android.util.Log; /** the following are for debugging purposes */ private String mSqlStmt = null; private Throwable mStackTrace = null; private final Throwable mStackTrace; /** when in cache and is in use, this member is set */ private boolean mInUse = false; Loading @@ -59,7 +59,11 @@ import android.util.Log; db.verifyLockOwner(); mDatabase = db; mSqlStmt = sql; if (StrictMode.vmSqliteObjectLeaksEnabled()) { mStackTrace = new DatabaseObjectNotClosedException().fillInStackTrace(); } else { mStackTrace = null; } nHandle = db.mNativeHandle; native_compile(sql); } Loading Loading @@ -112,7 +116,7 @@ import android.util.Log; // but if the database itself is not closed and is GC'ed, then // all sub-objects attached to the database could end up getting GC'ed too. // in that case, don't print any warning. if (mInUse && StrictMode.vmSqliteObjectLeaksEnabled()) { if (mInUse && mStackTrace != null) { int len = mSqlStmt.length(); StrictMode.onSqliteObjectLeaked( "Releasing statement in a finalizer. Please ensure " + Loading
core/java/android/database/sqlite/SQLiteCursor.java +6 −2 Original line number Diff line number Diff line Loading @@ -95,7 +95,11 @@ public class SQLiteCursor extends AbstractWindowedCursor { if (query.mDatabase == null) { throw new IllegalArgumentException("query.mDatabase cannot be null"); } if (StrictMode.vmSqliteObjectLeaksEnabled()) { mStackTrace = new DatabaseObjectNotClosedException().fillInStackTrace(); } else { mStackTrace = null; } mDriver = driver; mEditTable = editTable; mColumnNameMap = null; Loading Loading @@ -319,7 +323,7 @@ public class SQLiteCursor extends AbstractWindowedCursor { try { // if the cursor hasn't been closed yet, close it first if (mWindow != null) { if (StrictMode.vmSqliteObjectLeaksEnabled()) { if (mStackTrace != null) { int len = mQuery.mSql.length(); StrictMode.onSqliteObjectLeaked( "Finalizing a Cursor that has not been deactivated or closed. " + Loading