From: Daniel Golle Date: Thu, 26 Nov 2020 16:34:38 +0000 (+0000) Subject: jail: properly initialize timens_fd X-Git-Url: http://git.cdn.openwrt.org/?a=commitdiff_plain;h=31e0a46ded22a517c03cb899f890207f0db75fb8;p=project%2Fprocd.git jail: properly initialize timens_fd So we are safe for the future. Signed-off-by: Daniel Golle --- diff --git a/jail/jail.c b/jail/jail.c index 7ec6cd8..82ba4a5 100644 --- a/jail/jail.c +++ b/jail/jail.c @@ -2775,6 +2775,8 @@ static void post_main(struct uloop_timeout *t) if (opts.setns.time != -1) { timens_fd = ns_open_pid("time", getpid()); setns_open(CLONE_NEWTIME); + } else { + timens_fd = -1; } #endif