Sfoglia il codice sorgente

* fixed (real)modulename memory leak when changing the module name

git-svn-id: trunk@21954 -
Jonas Maebe 13 anni fa
parent
commit
ba4b08261c
1 ha cambiato i file con 2 aggiunte e 0 eliminazioni
  1. 2 0
      compiler/fmodule.pas

+ 2 - 0
compiler/fmodule.pas

@@ -965,6 +965,8 @@ implementation
 
     procedure tmodule.setmodulename(const s:string);
       begin
+        stringdispose(modulename);
+        stringdispose(realmodulename);
         modulename:=stringdup(upper(s));
         realmodulename:=stringdup(s);
         { also update asmlibrary names }