depot/third_party/nixpkgs/pkgs/os-specific/linux/mdadm/fix-hardcoded-mapdir.patch
Default email 587713944a Project import generated by Copybara.
GitOrigin-RevId: 6143fc5eeb9c4f00163267708e26191d1e918932
2024-04-21 17:54:59 +02:00

13 lines
385 B
Diff

diff --git a/udev.c b/udev.c
index bc4722b0..aa2a1a24 100644
--- a/udev.c
+++ b/udev.c
@@ -167,7 +167,7 @@ enum udev_status udev_block(char *devnm)
int fd;
char *path = xcalloc(1, BUFSIZ);
- snprintf(path, BUFSIZ, "/run/mdadm/creating-%s", devnm);
+ snprintf(path, BUFSIZ, "%s/creating-%s", MAP_DIR, devnm);
fd = open(path, O_CREAT | O_RDWR, 0600);
if (!is_fd_valid(fd)) {