chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fix util_lookup_group to handle large groups
[elogind.git]
/
extras
/
floppy
/
create_floppy_devices.c
diff --git
a/extras/floppy/create_floppy_devices.c
b/extras/floppy/create_floppy_devices.c
index 14df052cf7b7e4964edc220fb9863ca5735b99cc..2fc05cc4943387d66c2a3014deaeea1b90d2acf0 100644
(file)
--- a/
extras/floppy/create_floppy_devices.c
+++ b/
extras/floppy/create_floppy_devices.c
@@
-24,7
+24,8
@@
#include <pwd.h>
#include <grp.h>
#include <pwd.h>
#include <grp.h>
-#include "../../udev/udev.h"
+#include "libudev.h"
+#include "libudev-private.h"
static char *table[] = {
"", "d360", "h1200", "u360", "u720", "h360", "h720",
static char *table[] = {
"", "d360", "h1200", "u360", "u720", "h360", "h720",
@@
-66,7
+67,7
@@
int main(int argc, char **argv)
if (udev == NULL)
goto exit;
if (udev == NULL)
goto exit;
-
loggin
g_init("create_floppy_devices");
+
udev_lo
g_init("create_floppy_devices");
udev_set_log_fn(udev, log_fn);
udev_selinux_init(udev);
udev_set_log_fn(udev, log_fn);
udev_selinux_init(udev);
@@
-137,7
+138,7
@@
int main(int argc, char **argv)
return 1;
}
return 1;
}
- if (type < 0 || type >= (int)
(sizeof(table_sup) / sizeof(table_sup[0])
)) {
+ if (type < 0 || type >= (int)
ARRAY_SIZE(table_sup
)) {
fprintf(stderr,"Invalid CMOS type %d\n", type);
return 1;
}
fprintf(stderr,"Invalid CMOS type %d\n", type);
return 1;
}
@@
-164,6
+165,7
@@
int main(int argc, char **argv)
udev_selinux_exit(udev);
udev_unref(udev);
udev_selinux_exit(udev);
udev_unref(udev);
+ udev_log_close();
exit:
return 0;
}
exit:
return 0;
}