Fix missing installer initialization
The current_process field of struct installer was not initialized. Since the installer instance is static, its default value was 0. The call to installer_stop() then called kill(0, SIGTERM) (on Linux), which sent SIGTERM to every process in the process group. In particular, the scrcpy process was killed. As a consequence, the last cleanup steps, like disabling "show touches", were not executed. Fixes <https://github.com/Genymobile/scrcpy/issues/183>.
This commit is contained in:
parent
8890750681
commit
1a0139321b
1 changed files with 2 additions and 0 deletions
|
@ -79,6 +79,8 @@ SDL_bool installer_init(struct installer *installer, const char *serial) {
|
||||||
installer->initialized = SDL_FALSE;
|
installer->initialized = SDL_FALSE;
|
||||||
|
|
||||||
installer->stopped = SDL_FALSE;
|
installer->stopped = SDL_FALSE;
|
||||||
|
installer->current_process = PROCESS_NONE;
|
||||||
|
|
||||||
return SDL_TRUE;
|
return SDL_TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue