From e5ce58b3668925e352eb961aa71b200cc2edee09 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Minisini?= Date: Fri, 14 Jul 2023 19:42:09 +0200 Subject: [PATCH] Forgot to release tmeporary buffer and result when using RETURNING. [GB.DB] * BUG: Forgot to release tmeporary buffer and result when using RETURNING. --- main/lib/db/CResult.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/main/lib/db/CResult.c b/main/lib/db/CResult.c index 33eb46bfc..4f9f1286d 100644 --- a/main/lib/db/CResult.c +++ b/main/lib/db/CResult.c @@ -658,7 +658,7 @@ BEGIN_METHOD_VOID(Result_Update) DB_INFO *info = &THIS->info; int ret_first = -1; int ret_count = 0; - GB_VARIANT_VALUE *ret_buffer; + GB_VARIANT_VALUE *ret_buffer = NULL; bool err; DB_RESULT res; @@ -769,9 +769,13 @@ BEGIN_METHOD_VOID(Result_Update) THIS->buffer[i] = ret_buffer[j++]; } } + + THIS->driver->Result.Release(res, NULL, FALSE); } } + GB.Free(POINTER(&ret_buffer)); + break; case RESULT_EDIT: