Explorar o código

* avoid memory leak for copy of withnode in tempnodes

git-svn-id: trunk@6067 -
pierre %!s(int64=18) %!d(string=hai) anos
pai
achega
d5e4828f6f
Modificáronse 1 ficheiros con 4 adicións e 0 borrados
  1. 4 0
      compiler/nbas.pas

+ 4 - 0
compiler/nbas.pas

@@ -1015,6 +1015,10 @@ implementation
 
     destructor ttempdeletenode.destroy;
       begin
+        if assigned(tempinfo^.withnode) then
+          begin
+            tempinfo^.withnode.free;
+          end;
         dispose(tempinfo);
       end;