aboutsummaryrefslogtreecommitdiff
path: root/ell.c
diff options
context:
space:
mode:
authorPřemysl Janouch <p.janouch@gmail.com>2017-05-21 08:28:45 +0200
committerPřemysl Janouch <p.janouch@gmail.com>2017-05-21 13:19:48 +0200
commit706f452d9ddc180cf2fdaf9814778ee818661ee4 (patch)
treeef5d99ee89e57925fd93144dfd34034d0df6e480 /ell.c
parent567c3d8dc28e99278b5db0edf53e93783e835fe9 (diff)
downloadell-706f452d9ddc180cf2fdaf9814778ee818661ee4.tar.gz
ell-706f452d9ddc180cf2fdaf9814778ee818661ee4.tar.xz
ell-706f452d9ddc180cf2fdaf9814778ee818661ee4.zip
Fix memory leak on evaluation error
Diffstat (limited to 'ell.c')
-rwxr-xr-xell.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/ell.c b/ell.c
index 6becbe9..bdbc6fb 100755
--- a/ell.c
+++ b/ell.c
@@ -853,6 +853,9 @@ execute_statement
return true;
}
+ item_free_list (*result);
+ *result = NULL;
+
// In that case, `error' is NULL and there's nothing else to do anyway
if (!ctx->memory_failure) {
// This creates some form of a stack trace