Displaying 1 result from an estimated 1 matches for "ulong_from_sys_device_fil".
Did you mean:
ulong_from_sys_device_file
2005 Jan 06
0
skip unconnected interfaces
...06 15:24:48.038499880 -0700
@@ -27,6 +27,7 @@
static char do_not_config;
static unsigned int default_caps = CAP_DHCP | CAP_BOOTP | CAP_RARP;
static int loop_timeout = -1;
+static int only_connected = 0;
static int configured;
struct state {
@@ -290,6 +291,38 @@
return ret;
}
+static int ulong_from_sys_device_file(const char *path_prefix,
+ const char *dev_name,
+ const char *dev_file,
+ unsigned long *val)
+{
+ char t[PATH_MAX], p[255];
+ int i, fd, rc = -1;
+
+ i = snprintf(t, PATH_MAX-1, "%s/%s/%s", path_prefix, dev_name, dev_file);
+ if (i < 0 || i >= PATH_MAX-...