parted/fix-race-call-udevadm-settle.patch
OBS User autobuild eca291a9ed Accepting request 26270 from Base:System
Copy from Base:System/parted based on submit request 26270 from user puzel

OBS-URL: https://build.opensuse.org/request/show/26270
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/parted?expand=0&rev=44
2009-12-16 08:45:27 +00:00

20 lines
730 B
Diff

---
libparted/arch/linux.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
Index: parted-1.9.0/libparted/arch/linux.c
===================================================================
--- parted-1.9.0.orig/libparted/arch/linux.c 2009-12-11 12:04:43.000000000 +0100
+++ parted-1.9.0/libparted/arch/linux.c 2009-12-11 12:10:22.000000000 +0100
@@ -2224,7 +2224,9 @@ _blkpg_part_command (PedDevice* dev, str
ioctl_arg.datalen = sizeof (struct blkpg_partition);
ioctl_arg.data = (void*) part;
- return ioctl (arch_specific->fd, BLKPG, &ioctl_arg) == 0;
+ int ret = (ioctl (arch_specific->fd, BLKPG, &ioctl_arg) == 0);
+ system("/sbin/udevadm settle");
+ return ret;
}
static int