mirror of
https://github.com/rkd77/elinks.git
synced 2024-11-04 08:17:17 -05:00
b2556aa953
When ui.sessions.fork_on_start, we fork a process that has a different fdout than get_output_handle() (which has hardcoded fdout of 1), so it will never be considered term->master, yet this is the process we want to wake up in SIGTSTP handler. Since we cannot rely on term->master to determine if we are the master process, we instead move master_pid to be set explicitly at the places where we have information about whether our process is a master or a slave: first on start, then once the interlink determination has been made. master_pid has to be set in both parent and child, because both will get suspended and need to know which one needs to resume in background with SIGCONT (the master). We can't inherit from the parent because it's unknown at the time of fork. Previously, master_pid worked correctly with fork_on_start=0, -no-connect or -dump, but not with fork_on_start=1. See #287 for background. |
||
---|---|---|
.. | ||
color.c | ||
color.h | ||
draw.c | ||
draw.h | ||
event.c | ||
event.h | ||
hardio.c | ||
hardio.h | ||
itrm.h | ||
kbd.c | ||
kbd.h | ||
key.inc | ||
Makefile | ||
meson.build | ||
mouse.c | ||
mouse.h | ||
palette.inc | ||
screen.c | ||
screen.h | ||
sixel.c | ||
sixel.h | ||
tab.c | ||
tab.h | ||
terminal.c | ||
terminal.h | ||
terminfo.c | ||
terminfo.h | ||
TODO | ||
window.c | ||
window.h |