projects
/
oweals
/
netifd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b8ef742
)
system-linux: check for open failure
author
Günther Kelleter
<guenther.kelleter@devolo.de>
Thu, 3 Nov 2016 12:40:53 +0000
(13:40 +0100)
committer
Felix Fietkau
<nbd@nbd.name>
Fri, 4 Nov 2016 12:24:02 +0000
(13:24 +0100)
Signed-off-by: Günther Kelleter <guenther.kelleter@devolo.de>
system-linux.c
patch
|
blob
|
history
diff --git
a/system-linux.c
b/system-linux.c
index 6e4a1949a11874443e05d45ebf41e916fcf23219..a0389879c4d47c7a8ec8769b362aeb2cd1acb07f 100644
(file)
--- a/
system-linux.c
+++ b/
system-linux.c
@@
-2489,6
+2489,8
@@
int system_update_ipv6_mtu(struct device *dev, int mtu)
dev->ifname);
int fd = open(buf, O_RDWR);
+ if (fd < 0)
+ return ret;
if (!mtu) {
ssize_t len = read(fd, buf, sizeof(buf) - 1);