04ddaa4bc5
add cmirror version OBS-URL: https://build.opensuse.org/request/show/236202 OBS-URL: https://build.opensuse.org/package/show/Base:System/lvm2?expand=0&rev=96
28 lines
845 B
Diff
28 lines
845 B
Diff
Index: LVM2.2.02.98/scripts/lvm2_activation_generator_systemd_red_hat.c
|
|
===================================================================
|
|
--- LVM2.2.02.98.orig/scripts/lvm2_activation_generator_systemd_red_hat.c
|
|
+++ LVM2.2.02.98/scripts/lvm2_activation_generator_systemd_red_hat.c
|
|
@@ -145,6 +145,7 @@ int main(int argc, char *argv[])
|
|
{
|
|
const char *dir;
|
|
int r = EXIT_SUCCESS;
|
|
+ mode_t old_mask;
|
|
|
|
kmsg_fd = open(KMSG_DEV_PATH, O_WRONLY|O_NOCTTY);
|
|
|
|
@@ -158,9 +159,13 @@ int main(int argc, char *argv[])
|
|
goto out;
|
|
|
|
dir = argc > 1 ? argv[1] : DEFAULT_UNIT_DIR;
|
|
-
|
|
+
|
|
+ /* mark lvm2-activation.*.service as world-accessible */
|
|
+ old_mask = umask(0022);
|
|
if (!generate_unit(dir, 1) || !generate_unit(dir, 0))
|
|
r = EXIT_FAILURE;
|
|
+ umask(old_mask);
|
|
+
|
|
out:
|
|
if (r)
|
|
kmsg("LVM: Activation generator failed.\n");
|