]> granicus.if.org Git - procps-ng/commitdiff
Avoid confusing messages caused by EIO on reading
authorWerner Fink <werner@suse.de>
Fri, 7 Jul 2017 12:09:12 +0000 (14:09 +0200)
committerCraig Small <csmall@enc.com.au>
Wed, 30 Aug 2017 12:39:56 +0000 (22:39 +1000)
/proc/sys/net/ipv6/conf/*/stable_secret if those are not set yet.

Signed-off-by: Werner Fink <werner@suse.de>
sysctl.c

index be057229a7917ff46fa24c98035785723ff18b89..aadc2330f0e945b75d1332b1a99307f0edbdebde 100644 (file)
--- a/sysctl.c
+++ b/sysctl.c
@@ -237,6 +237,9 @@ static int ReadSetting(const char *restrict const name)
                        xwarnx(_("permission denied on key '%s'"), outname);
                        rc = -1;
                        break;
+               case EIO:           /* Ignore stable_secret below /proc/sys/net/ipv6/conf */
+                       rc = -1;
+                       break;
                default:
                        xwarn(_("reading key \"%s\""), outname);
                        rc = -1;
@@ -286,6 +289,9 @@ static int ReadSetting(const char *restrict const name)
                                        rc = DisplayAll(tmpname);
                                        goto out;
                                }
+                       case EIO:           /* Ignore stable_secret below /proc/sys/net/ipv6/conf */
+                               rc = -1;
+                               break;
                        default:
                                xwarnx(_("reading key \"%s\""), outname);
                                rc = -1;