From: Adam Dickmeiss Date: Tue, 22 Apr 2014 19:05:41 +0000 (+0200) Subject: Don't call filter destructors on SIGTERM CP-3770 X-Git-Url: http://sru.miketaylor.org.uk/cgi-bin?a=commitdiff_plain;h=810854d9952a7720738ac6e09ec4065de298ee02;p=metaproxy-moved-to-github.git Don't call filter destructors on SIGTERM CP-3770 --- diff --git a/src/metaproxy_prog.cpp b/src/metaproxy_prog.cpp index fa0ea33..167a58a 100644 --- a/src/metaproxy_prog.cpp +++ b/src/metaproxy_prog.cpp @@ -87,8 +87,12 @@ static void work_common(void *data) mp::Package pack; pack.router(*routerp).move(); yaz_log(YLOG_LOG, "metaproxy stop"); - delete routerp; - routerp = 0; + + if (sig_received != SIGTERM) + { + delete routerp; + routerp = 0; + } _exit(0); }