From: Roy Marples Date: Wed, 9 Jul 2008 21:15:26 +0000 (+0000) Subject: Report the reason we exec the script and don't error on deleting non existant routes... X-Git-Tag: v4.0.2~221 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=378b0716112fab6b8e72843ef0f9c47c8ba4c089;p=thirdparty%2Fdhcpcd.git Report the reason we exec the script and don't error on deleting non existant routes on Linux. --- diff --git a/configure.c b/configure.c index c761ab75..47c9bcc4 100644 --- a/configure.c +++ b/configure.c @@ -63,7 +63,7 @@ exec_script(const struct options *options, const char *iface, sigset_t full; sigset_t old; - logger(LOG_DEBUG, "executing `%s'", options->script); + logger(LOG_DEBUG, "executing `%s', reason %s", options->script, reason); /* Make our env */ elen = 5; @@ -197,10 +197,9 @@ delete_route(const char *iface, struct rt *rt, int metric) addr, inet_ntocidr(rt->net), inet_ntoa(rt->gate)); free(addr); retval = del_route(iface, &rt->dest, &rt->net, &rt->gate, metric); - if (retval != 0 && errno != ENOENT) + if (retval != 0 && errno != ENOENT && errno != ESRCH) logger(LOG_ERR," del_route: %s", strerror(errno)); return retval; - } static int