From 6e2694ef08f394931c9e467904e256f38a77f421 Mon Sep 17 00:00:00 2001 From: Packit Service Date: Jan 28 2021 16:14:58 +0000 Subject: Apply patch 0041-nft-Fix-command-name-in-ip6tables-error-message.patch patch_name: 0041-nft-Fix-command-name-in-ip6tables-error-message.patch present_in_specfile: true location_in_specfile: 41 --- diff --git a/iptables/xtables-standalone.c b/iptables/xtables-standalone.c index 022d5dd..b5b7cca 100644 --- a/iptables/xtables-standalone.c +++ b/iptables/xtables-standalone.c @@ -74,14 +74,10 @@ xtables_main(int family, const char *progname, int argc, char *argv[]) nft_fini(&h); if (!ret) { - if (errno == EINVAL) { - fprintf(stderr, "iptables: %s. " - "Run `dmesg' for more information.\n", - nft_strerror(errno)); - } else { - fprintf(stderr, "iptables: %s.\n", - nft_strerror(errno)); - } + fprintf(stderr, "%s: %s.%s\n", progname, nft_strerror(errno), + (errno == EINVAL ? + " Run `dmesg' for more information." : "")); + if (errno == EAGAIN) exit(RESOURCE_PROBLEM); }