Browse Source

compiler: set to nil after free

mattias 6 days ago
parent
commit
fbd36fe22e
1 changed files with 2 additions and 0 deletions
  1. 2 0
      compiler/nobj.pas

+ 2 - 0
compiler/nobj.pas

@@ -977,6 +977,7 @@ implementation
                       prot_get_procdefs_recursive(ImplIntf,ImplIntf.IntfDef);
                     end;
                   handledprotocols.free;
+                  handledprotocols := nil;
                 end
               else
                 internalerror(2009091801);
@@ -992,6 +993,7 @@ implementation
         vmtbuilder:=TVMTBuilder.create(def);
         vmtbuilder.build;
         vmtbuilder.free;
+        vmtbuilder := nil;
       end;
 
 end.