Explorar o código

[process] small leak fixed

Exilon %!s(int64=4) %!d(string=hai) anos
pai
achega
47c0700261
Modificáronse 1 ficheiros con 5 adicións e 1 borrados
  1. 5 1
      Quick.Process.pas

+ 5 - 1
Quick.Process.pas

@@ -514,7 +514,11 @@ begin
       pclose(Handle);
     end;
   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;