From 9747d1a62c9c4868f7093e57dea9915d64268e78 Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Thu, 14 Dec 2017 06:31:52 +1030 Subject: [PATCH] database: don't leak query string. Signed-off-by: Rusty Russell --- wallet/db.c | 1 + 1 file changed, 1 insertion(+) diff --git a/wallet/db.c b/wallet/db.c index 64b9e8b7f..26d6c8718 100644 --- a/wallet/db.c +++ b/wallet/db.c @@ -223,6 +223,7 @@ sqlite3_stmt *PRINTF_FMT(3, 4) /* Sets stmt to NULL if not SQLITE_OK */ sqlite3_prepare_v2(db->sql, query, -1, &stmt, NULL); + tal_free(query); return stmt; }