forked from pool/systemd
039f4cc39b
add: 1008-udev-path_id-handle-Hyper-V-devices.patch - keymap: Update the list of Samsung Series 9 models add: 1009-keymap-Update-the-list-of-Samsung-Series-9-models.patch - keymap: Add Samsung 700T add: 1010-keymap-Add-Samsung-700T.patch - libudev: avoid leak during realloc failure add: 1011-libudev-avoid-leak-during-realloc-failure.patch - libudev: do not resolve $attr{device} symlinks add: 1012-libudev-do-not-resolve-attr-device-symlinks.patch - libudev: validate 'udev' argument to udev_enumerate_new() add: 1013-libudev-validate-udev-argument-to-udev_enumerate_new.patch - udev: fix whitespace add: 1014-udev-fix-whitespace.patch - udev: properly handle symlink removal by 'change' event add: 1015-udev-properly-handle-symlink-removal-by-change-event.patch - udev: builtin - do not fail builtin initialization if one of them returns an error add: 1016-udev-builtin-do-not-fail-builtin-initialization-if-o.patch - udev: use usec_t and now() add: 1017-udev-use-usec_t-and-now.patch closing an non-existent dbus connection and getting assertion failures. - udev: path_id - handle Hyper-V devices add: 1008-udev-path_id-handle-Hyper-V-devices.patch - keymap: Update the list of Samsung Series 9 models add: 1009-keymap-Update-the-list-of-Samsung-Series-9-models.patch - keymap: Add Samsung 700T add: 1010-keymap-Add-Samsung-700T.patch OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd?expand=0&rev=327
65 lines
2.2 KiB
Diff
65 lines
2.2 KiB
Diff
Index: systemd-195/src/udev/udev-builtin.c
|
|
===================================================================
|
|
--- systemd-195.orig/src/udev/udev-builtin.c
|
|
+++ systemd-195/src/udev/udev-builtin.c
|
|
@@ -42,24 +42,18 @@ static const struct udev_builtin *builti
|
|
#endif
|
|
};
|
|
|
|
-int udev_builtin_init(struct udev *udev)
|
|
+void udev_builtin_init(struct udev *udev)
|
|
{
|
|
unsigned int i;
|
|
- int err = 0;
|
|
|
|
if (initialized)
|
|
- return 0;
|
|
+ return;
|
|
|
|
- for (i = 0; i < ELEMENTSOF(builtins); i++) {
|
|
- if (builtins[i]->init) {
|
|
- err = builtins[i]->init(udev);
|
|
- if (err < 0)
|
|
- break;
|
|
- }
|
|
- }
|
|
+ for (i = 0; i < ELEMENTSOF(builtins); i++)
|
|
+ if (builtins[i]->init)
|
|
+ builtins[i]->init(udev);
|
|
|
|
initialized = true;
|
|
- return err;
|
|
}
|
|
|
|
void udev_builtin_exit(struct udev *udev)
|
|
@@ -79,13 +73,11 @@ void udev_builtin_exit(struct udev *udev
|
|
bool udev_builtin_validate(struct udev *udev)
|
|
{
|
|
unsigned int i;
|
|
- bool change = false;
|
|
|
|
for (i = 0; i < ELEMENTSOF(builtins); i++)
|
|
- if (builtins[i]->validate)
|
|
- if (builtins[i]->validate(udev))
|
|
- change = true;
|
|
- return change;
|
|
+ if (builtins[i]->validate && builtins[i]->validate(udev))
|
|
+ return true;
|
|
+ return false;
|
|
}
|
|
|
|
void udev_builtin_list(struct udev *udev)
|
|
Index: systemd-195/src/udev/udev.h
|
|
===================================================================
|
|
--- systemd-195.orig/src/udev/udev.h
|
|
+++ systemd-195/src/udev/udev.h
|
|
@@ -167,7 +167,7 @@ extern const struct udev_builtin udev_bu
|
|
extern const struct udev_builtin udev_builtin_usb_db;
|
|
extern const struct udev_builtin udev_builtin_usb_id;
|
|
extern const struct udev_builtin udev_builtin_uaccess;
|
|
-int udev_builtin_init(struct udev *udev);
|
|
+void udev_builtin_init(struct udev *udev);
|
|
void udev_builtin_exit(struct udev *udev);
|
|
enum udev_builtin_cmd udev_builtin_lookup(const char *command);
|
|
const char *udev_builtin_name(enum udev_builtin_cmd cmd);
|