diff options
| author | Juan Linietsky | 2014-12-16 22:31:57 -0300 |
|---|---|---|
| committer | Juan Linietsky | 2014-12-16 22:31:57 -0300 |
| commit | bcf27feb980aec593c7cb771984e46113cfad757 (patch) | |
| tree | dabc98af627732ccf5d1bbfa8aa58348030f6324 /drivers/unix/os_unix.cpp | |
| parent | be4e40e90a5a322f6a7cec4893854ef5b15db600 (diff) | |
| download | godot-bcf27feb980aec593c7cb771984e46113cfad757.tar.gz godot-bcf27feb980aec593c7cb771984e46113cfad757.tar.zst godot-bcf27feb980aec593c7cb771984e46113cfad757.zip | |
Diffstat (limited to 'drivers/unix/os_unix.cpp')
| -rw-r--r-- | drivers/unix/os_unix.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/unix/os_unix.cpp b/drivers/unix/os_unix.cpp index e6458068e..2de975e5d 100644 --- a/drivers/unix/os_unix.cpp +++ b/drivers/unix/os_unix.cpp @@ -332,6 +332,12 @@ Error OS_Unix::execute(const String& p_path, const List<String>& p_arguments,boo Error OS_Unix::kill(const ProcessID& p_pid) { int ret = ::kill(p_pid,SIGKILL); + if (!ret) { + //avoid zombie process + int st; + ::waitpid(p_pid,&st,0); + + } return ret?ERR_INVALID_PARAMETER:OK; } |
