Selaa lähdekoodia

[process] small leak fixed

Exilon 4 vuotta sitten
vanhempi
commit
47c0700261
1 muutettua tiedostoa jossa 5 lisäystä ja 1 poistoa
  1. 5 1
      Quick.Process.pas

+ 5 - 1
Quick.Process.pas

@@ -514,7 +514,11 @@ begin
       pclose(Handle);
       pclose(Handle);
     end;
     end;
   except
   except
-    on E: Exception do Exception.CreateFmt('RunCommand: %s',[e.Message]);
+    on E: Exception do
+    begin
+      Result.Free;
+      Exception.CreateFmt('RunCommand: %s',[e.Message]);
+    end;
   end;
   end;
 end;
 end;