Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F162327603
D52132.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
660 B
Referenced Files
None
Subscribers
None
D52132.diff
View Options
diff --git a/sys/netlink/route/iface_drivers.c b/sys/netlink/route/iface_drivers.c
--- a/sys/netlink/route/iface_drivers.c
+++ b/sys/netlink/route/iface_drivers.c
@@ -93,7 +93,12 @@
if (lattrs->ifla_mtu > 0) {
if (nlp_has_priv(npt->nlp, PRIV_NET_SETIFMTU)) {
struct ifreq ifr = { .ifr_mtu = lattrs->ifla_mtu };
- error = ifhwioctl(SIOCSIFMTU, ifp, (char *)&ifr, curthread);
+ error = ifhwioctl(SIOCSIFMTU, ifp, (char *)&ifr,
+ curthread);
+ if (error != 0) {
+ nlmsg_report_err_msg(npt, "Failed to set mtu");
+ return (error);
+ }
} else {
nlmsg_report_err_msg(npt, "Not enough privileges to set mtu");
return (EPERM);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, Jul 13, 2:33 AM (4 h, 27 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
35021820
Default Alt Text
D52132.diff (660 B)
Attached To
Mode
D52132: netlink: Handle `ifhwioctl(SIOCSIFMTU)` failure
Attached
Detach File
Event Timeline
Log In to Comment