Skip to content

Commit 6b67d90

Browse files
committed
VB08-005 Free Symbols_Table on early return
1 parent 8ca1051 commit 6b67d90

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

source/ada/lsp-lal_utils.adb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1661,9 +1661,11 @@ package body LSP.Lal_Utils is
16611661
if In_Sloc = Langkit_Support.Slocs.No_Source_Location_Range then
16621662
-- Return full range of Output
16631663
Out_Sloc := In_Sloc;
1664+
Langkit_Support.Symbols.Destroy (Symbols);
16641665
return;
16651666
elsif Node.Unit.Token_Count = 0 then -- Ignore a cornercase for now
16661667
Out_Sloc := Langkit_Support.Slocs.No_Source_Location_Range;
1668+
Langkit_Support.Symbols.Destroy (Symbols);
16671669
return;
16681670
end if;
16691671

0 commit comments

Comments
 (0)