ifupdown: only display skip messages in verbose mode

This commit is contained in:
Ariadne Conill 2020-09-09 19:38:29 -06:00
parent a6e022ad99
commit ceb82f4fd2

View file

@ -101,14 +101,16 @@ skip_interface(struct lif_interface *iface, const char *ifname)
if (up && iface->refcount > 0) if (up && iface->refcount > 0)
{ {
fprintf(stderr, "%s: skipping %s (already configured), use --force to force configuration\n", if (exec_opts.verbose)
fprintf(stderr, "%s: skipping auto interface %s (already configured), use --force to force configuration\n",
argv0, ifname); argv0, ifname);
return true; return true;
} }
if (!up && iface->refcount == 0) if (!up && iface->refcount == 0)
{ {
fprintf(stderr, "%s: skipping %s (already deconfigured), use --force to force deconfiguration\n", if (exec_opts.verbose)
fprintf(stderr, "%s: skipping auto interface %s (already deconfigured), use --force to force deconfiguration\n",
argv0, ifname); argv0, ifname);
return true; return true;
} }