summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--net/ipv6/addrconf.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c
index 17f8e7ea133b..1f21087accab 100644
--- a/net/ipv6/addrconf.c
+++ b/net/ipv6/addrconf.c
@@ -5369,13 +5369,10 @@ static int addrconf_sysctl_stable_secret(struct ctl_table *ctl, int write,
5369 goto out; 5369 goto out;
5370 } 5370 }
5371 5371
5372 if (!write) { 5372 err = snprintf(str, sizeof(str), "%pI6", &secret->secret);
5373 err = snprintf(str, sizeof(str), "%pI6", 5373 if (err >= sizeof(str)) {
5374 &secret->secret); 5374 err = -EIO;
5375 if (err >= sizeof(str)) { 5375 goto out;
5376 err = -EIO;
5377 goto out;
5378 }
5379 } 5376 }
5380 5377
5381 err = proc_dostring(&lctl, write, buffer, lenp, ppos); 5378 err = proc_dostring(&lctl, write, buffer, lenp, ppos);