diff options
author | pommicket <pommicket@gmail.com> | 2023-01-02 14:10:38 -0500 |
---|---|---|
committer | pommicket <pommicket@gmail.com> | 2023-01-02 14:10:38 -0500 |
commit | f791aa01fad7e81223808584212c6a1a4c80ca07 (patch) | |
tree | f93d53a62035cdad7f16b97fb28c83c7acfaf14f /os-posix.c | |
parent | c0d0117a963cf8e4dfb28b919087d8a8ecbbca6e (diff) |
finish restructuring
Diffstat (limited to 'os-posix.c')
-rw-r--r-- | os-posix.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -1,4 +1,5 @@ #include "os.h" +#include "util.h" #include <sys/types.h> #include <sys/stat.h> #include <sys/wait.h> @@ -178,7 +179,6 @@ Process *process_run_ex(const char *command, const ProcessSettings *settings) { } } - bool success = false; pid_t pid = fork(); if (pid == 0) { // child process @@ -295,6 +295,7 @@ void process_kill(Process *proc) { waitpid(proc->pid, NULL, 0); proc->pid = 0; process_close_pipes(proc); + free(proc); } int process_check_status(Process *proc, char *message, size_t message_size) { |