mirror of
https://github.com/edeproject/ede.git
synced 2023-08-10 21:13:03 +03:00
Reworked process handler due a large number of races. Now process reports
should not interfere with popped up message boxes. Still there is a issue with childs during splash startup: when one of them crashes with core dump crash dialog will not be shown, but the main process handler correctly returns crash flag.
This commit is contained in:
@ -33,15 +33,23 @@ struct EvokeProcess {
|
||||
pid_t pid;
|
||||
};
|
||||
|
||||
typedef edelib::list<EvokeClient> ClientList;
|
||||
struct QueuedSignal {
|
||||
pid_t pid;
|
||||
int signum;
|
||||
};
|
||||
|
||||
typedef edelib::list<EvokeClient> ClientList;
|
||||
typedef edelib::list<EvokeClient>::iterator ClientListIter;
|
||||
|
||||
typedef edelib::list<edelib::String> StringList;
|
||||
typedef edelib::list<edelib::String> StringList;
|
||||
typedef edelib::list<edelib::String>::iterator StringListIter;
|
||||
|
||||
typedef edelib::list<EvokeProcess> ProcessList;
|
||||
typedef edelib::list<EvokeProcess> ProcessList;
|
||||
typedef edelib::list<EvokeProcess>::iterator ProcessListIter;
|
||||
|
||||
typedef edelib::list<QueuedSignal> SignalQueue;
|
||||
typedef edelib::list<QueuedSignal>::iterator SignalQueueIter;
|
||||
|
||||
class Fl_Double_Window;
|
||||
|
||||
class EvokeService {
|
||||
@ -58,6 +66,10 @@ class EvokeService {
|
||||
|
||||
ClientList clients;
|
||||
ProcessList processes;
|
||||
int quit_child_pid;
|
||||
int quit_child_ret;
|
||||
int wake_up_pipe[2];
|
||||
|
||||
|
||||
public:
|
||||
EvokeService();
|
||||
@ -68,6 +80,7 @@ class EvokeService {
|
||||
void stop(void) { is_running = false; }
|
||||
bool running(void) { return is_running; }
|
||||
|
||||
bool setup_channels(void);
|
||||
bool setup_logging(const char* file);
|
||||
bool setup_pid(const char* file, const char* lock);
|
||||
void setup_atoms(Display* d);
|
||||
@ -82,8 +95,9 @@ class EvokeService {
|
||||
Log* log(void) { return logfile; }
|
||||
|
||||
void service_watcher(int pid, int signum);
|
||||
void wake_up(int fd);
|
||||
|
||||
void run_program(const char* cmd, bool enable_vars = 1);
|
||||
//void heuristic_run_program(const char* cmd);
|
||||
void register_process(const char* cmd, pid_t pid);
|
||||
void unregister_process(pid_t pid);
|
||||
bool find_and_unregister_process(pid_t pid, EvokeProcess& pc);
|
||||
|
Reference in New Issue
Block a user