You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

32 lines
1.0 KiB

From 2d0eff7f56936823d784425d2171be295ba11027 Mon Sep 17 00:00:00 2001
From: Yousong Zhou <yszhou4tech@gmail.com>
Date: Fri, 15 May 2015 15:55:10 +0800
Subject: [PATCH 209/210] xl2tpd: ignore SIGPIPE signal.
---
xl2tpd.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/xl2tpd.c b/xl2tpd.c
index c11fe66..58ed868 100644
--- a/xl2tpd.c
+++ b/xl2tpd.c
@@ -1551,7 +1551,6 @@ void do_control ()
/*FIXME: check quotes to allow filenames with spaces?
(do not forget quotes escaping to allow filenames with quotes)*/
- /*FIXME: write to res_filename may cause SIGPIPE, need to catch it*/
resf = fopen (res_filename, "w");
if (!resf) {
l2tp_log (LOG_DEBUG, "%s: Can't open result file %s\n",
@@ -1811,6 +1810,7 @@ void init (int argc,char *argv[])
signal (SIGCHLD, &sigchld_handler);
signal (SIGUSR1, &sigusr1_handler);
signal (SIGHUP, &sighup_handler);
+ signal (SIGPIPE, SIG_IGN);
init_scheduler ();
unlink(gconfig.controlfile);
--
1.7.10.4