]> git.ipfire.org Git - thirdparty/systemd.git/blobdiff - src/shared/ethtool-util.c
tree-wide: use -EBADF for fd initialization
[thirdparty/systemd.git] / src / shared / ethtool-util.c
index e39b2f754bbe2dcd5a25d79afea4e8caee756864..e2b2ca235298b23af3b47f77bb60b5d21bd88c81 100644 (file)
@@ -349,7 +349,7 @@ int ethtool_get_link_info(
 }
 
 int ethtool_get_permanent_hw_addr(int *ethtool_fd, const char *ifname, struct hw_addr_data *ret) {
-        _cleanup_close_ int fd = -1;
+        _cleanup_close_ int fd = -EBADF;
         struct {
                 struct ethtool_perm_addr addr;
                 uint8_t space[HW_ADDR_MAX_SIZE];