From aa39264afda86afc6efafafcc7be8d8cf598b79a Mon Sep 17 00:00:00 2001
From: "Samuel H. Kenyon" <skenyon@basistech.com>
Date: Tue, 5 Nov 2013 15:28:54 -0500
Subject: [PATCH] Set the add prepared statement to NULL after finalizing it.

---
 tsk/hashdb/sqlite_index.cpp | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/tsk/hashdb/sqlite_index.cpp b/tsk/hashdb/sqlite_index.cpp
index 3ff82422c..e5316e76e 100644
--- a/tsk/hashdb/sqlite_index.cpp
+++ b/tsk/hashdb/sqlite_index.cpp
@@ -720,6 +720,8 @@ sqlite_v1_close(TSK_IDX_INFO * idx_info)
         finalize_stmt(m_stmt);
     }
 
+    m_stmt = NULL;
+
     if (idx_info->idx_struct.idx_sqlite_v1->hIdx_sqlite) {
         sqlite3_close(idx_info->idx_struct.idx_sqlite_v1->hIdx_sqlite);
     }
-- 
GitLab