Mercurial > illumos > illumos-gate
changeset 11255:ffdbe2f24fa6
6905775 libdiskmgt no longer correctly accessing extended partitions
author | Virginia Wray <Virginia.Wray@Sun.COM> |
---|---|
date | Fri, 04 Dec 2009 17:08:31 -0700 |
parents | 96d4e4c1da62 |
children | 4dbbde47c138 |
files | usr/src/lib/libdiskmgt/common/partition.c |
diffstat | 1 files changed, 2 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/usr/src/lib/libdiskmgt/common/partition.c Fri Dec 04 14:47:56 2009 -0800 +++ b/usr/src/lib/libdiskmgt/common/partition.c Fri Dec 04 17:08:31 2009 -0700 @@ -624,16 +624,14 @@ if (!fdisk_is_dos_extended(iparts[i].systid)) continue; - len = strlen(disk->aliases->alias) + strlen("/dev/rdsk/") + 1; + len = strlen(disk->aliases->alias) + 1; if ((device = malloc(len)) == NULL) { if (device) free(device); continue; } - /* Check the above fix w Jean */ - (void) snprintf(device, len, "/dev/rdsk/%s", - disk->aliases->alias); + (void) snprintf(device, len, "%s", disk->aliases->alias); if ((ret = libfdisk_init(&epp, device, &iparts[i], FDISK_READ_DISK)) != FDISK_SUCCESS) {