summaryrefslogtreecommitdiff
path: root/accel-pptpd/triton
diff options
context:
space:
mode:
authorKozlov Dmitry <dima@server>2010-09-14 15:56:31 +0400
committerKozlov Dmitry <dima@server>2010-09-14 16:05:10 +0400
commitd860a4beaf5f99d5045d03b931b4829426a2f7b0 (patch)
tree377f0cf851020786f5e40f70644a3dafbc63ce14 /accel-pptpd/triton
parenta670641cc3c420bfd9026d3711501663aef88287 (diff)
downloadaccel-ppp-d860a4beaf5f99d5045d03b931b4829426a2f7b0.tar.gz
accel-ppp-d860a4beaf5f99d5045d03b931b4829426a2f7b0.zip
extra: implemented module 'pppd_compat' which starts pppd compatible scripts ip-up, ip-down,
and newly introduced - ip-change, when radius CoA request received, also this module manages pppd compatible radattr.pppX files core: implemented module 'sigchld' which handles SIGCHLD signal, waits child processes to terminate and manages pid terminate handlers
Diffstat (limited to 'accel-pptpd/triton')
-rw-r--r--accel-pptpd/triton/triton.c11
-rw-r--r--accel-pptpd/triton/triton.h7
2 files changed, 18 insertions, 0 deletions
diff --git a/accel-pptpd/triton/triton.c b/accel-pptpd/triton/triton.c
index b0aedbc..9b9fd75 100644
--- a/accel-pptpd/triton/triton.c
+++ b/accel-pptpd/triton/triton.c
@@ -35,6 +35,17 @@ static void* triton_thread(struct _triton_thread_t *thread)
sigset_t set;
int sig;
+ sigfillset(&set);
+ pthread_sigmask(SIG_BLOCK, &set, NULL);
+
+ sigdelset(&set, SIGUSR1);
+ sigdelset(&set, SIGQUIT);
+ sigdelset(&set, SIGSEGV);
+ sigdelset(&set, SIGFPE);
+ sigdelset(&set, SIGILL);
+ sigdelset(&set, SIGBUS);
+ pthread_sigmask(SIG_UNBLOCK, &set, NULL);
+
sigemptyset(&set);
sigaddset(&set, SIGUSR1);
sigaddset(&set, SIGQUIT);
diff --git a/accel-pptpd/triton/triton.h b/accel-pptpd/triton/triton.h
index b1df497..8510a51 100644
--- a/accel-pptpd/triton/triton.h
+++ b/accel-pptpd/triton/triton.h
@@ -29,6 +29,13 @@ struct triton_timer_t
void (*expire)(struct triton_timer_t *);
};
+struct triton_sigchld_handler_t
+{
+ void *tpd;
+ int pid;
+ void (*handler)(struct triton_sigchld_handler_t *h, int status);
+};
+
struct conf_option_t
{
struct list_head entry;