From: Kay Sievers Date: Sat, 18 Oct 2008 17:30:42 +0000 (+0200) Subject: selinux_init(udev) -> udev_selinux_init(udev) X-Git-Tag: 174~1415 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c3b1fa66d2685780e60e4c5b8bc0c2e717c1ee71;p=systemd selinux_init(udev) -> udev_selinux_init(udev) --- diff --git a/udev/test-udev.c b/udev/test-udev.c index 1cc83c4a..76045132 100644 --- a/udev/test-udev.c +++ b/udev/test-udev.c @@ -58,7 +58,7 @@ int main(int argc, char *argv[]) if (udev == NULL) exit(1); info(udev, "version %s\n", VERSION); - selinux_init(udev); + udev_selinux_init(udev); /* set signal handlers */ memset(&act, 0x00, sizeof(act)); @@ -111,7 +111,7 @@ int main(int argc, char *argv[]) fail: udev_rules_unref(rules); exit: - selinux_exit(udev); + udev_selinux_exit(udev); udev_unref(udev); if (err != 0) return 1; diff --git a/udev/udev-selinux.c b/udev/udev-selinux.c index cf7f4349..cd86870b 100644 --- a/udev/udev-selinux.c +++ b/udev/udev-selinux.c @@ -29,7 +29,7 @@ static int selinux_enabled; security_context_t selinux_prev_scontext; -void selinux_init(struct udev *udev) +void udev_selinux_init(struct udev *udev) { /* record the present security context */ selinux_enabled = (is_selinux_enabled() > 0); @@ -43,7 +43,7 @@ void selinux_init(struct udev *udev) } } -void selinux_exit(struct udev *udev) +void udev_selinux_exit(struct udev *udev) { if (!selinux_enabled) return; diff --git a/udev/udev.h b/udev/udev.h index c73ec906..66ad73ad 100644 --- a/udev/udev.h +++ b/udev/udev.h @@ -119,14 +119,14 @@ extern int run_program(struct udev *udev, const char *command, char **envp, /* udev-selinux.c */ #ifndef USE_SELINUX -static inline void selinux_init(struct udev *udev) {} -static inline void selinux_exit(struct udev *udev) {} +static inline void udev_selinux_init(struct udev *udev) {} +static inline void udev_selinux_exit(struct udev *udev) {} static inline void udev_selinux_lsetfilecon(struct udev *udev, const char *file, unsigned int mode) {} static inline void udev_selinux_setfscreatecon(struct udev *udev, const char *file, unsigned int mode) {} static inline void udev_selinux_resetfscreatecon(struct udev *udev) {} #else -extern void selinux_init(struct udev *udev); -extern void selinux_exit(struct udev *udev); +extern void udev_selinux_init(struct udev *udev); +extern void udev_selinux_exit(struct udev *udev); extern void udev_selinux_lsetfilecon(struct udev *udev, const char *file, unsigned int mode); extern void udev_selinux_setfscreatecon(struct udev *udev, const char *file, unsigned int mode); extern void udev_selinux_resetfscreatecon(struct udev *udev); diff --git a/udev/udevadm.c b/udev/udevadm.c index 8fd976a6..2de9fbcf 100644 --- a/udev/udevadm.c +++ b/udev/udevadm.c @@ -140,7 +140,7 @@ int main(int argc, char *argv[]) logging_init("udevadm"); udev_set_log_fn(udev, log_fn); - selinux_init(udev); + udev_selinux_init(udev); /* see if we are a compat link, this will be removed in a future release */ command = argv[0]; @@ -210,7 +210,7 @@ int main(int argc, char *argv[]) help(udev, argc, argv); rc = 2; out: - selinux_exit(udev); + udev_selinux_exit(udev); udev_unref(udev); logging_close(); return rc; diff --git a/udev/udevd.c b/udev/udevd.c index f8129403..4f46b6c1 100644 --- a/udev/udevd.c +++ b/udev/udevd.c @@ -648,7 +648,7 @@ int main(int argc, char *argv[]) logging_init("udevd"); udev_set_log_fn(udev, log_fn); info(udev, "version %s\n", VERSION); - selinux_init(udev); + udev_selinux_init(udev); while (1) { int option; @@ -978,7 +978,7 @@ exit: close(inotify_fd); udev_monitor_unref(kernel_monitor); - selinux_exit(udev); + udev_selinux_exit(udev); udev_unref(udev); logging_close(); return rc;