From c9ebd08dd8f218017c1f0afb21193df43aaf512f Mon Sep 17 00:00:00 2001 From: XZ-X Date: Mon, 16 Dec 2024 12:23:15 -0500 Subject: [PATCH] fix potential memory leak --- src/context.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/context.cpp b/src/context.cpp index 7fa7d78183..4aff0ceae2 100644 --- a/src/context.cpp +++ b/src/context.cpp @@ -291,6 +291,8 @@ namespace Sass { stack += "\n " + sass::string(File::abs2rel(import_stack[n]->abs_path, cwd, cwd)) + " imports " + sass::string(File::abs2rel(import_stack[n+1]->abs_path, cwd, cwd)); } + sass_delete_import(import_stack.back()); + delete source; // implement error throw directly until we // decided how to handle full stack traces throw Exception::InvalidSyntax(pstate, traces, stack);