diff options
Diffstat (limited to 'fdisk')
-rw-r--r-- | fdisk/sfdisk.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/fdisk/sfdisk.c b/fdisk/sfdisk.c index 2cda03ceb..da779aa89 100644 --- a/fdisk/sfdisk.c +++ b/fdisk/sfdisk.c @@ -2432,14 +2432,15 @@ is_ide_cdrom_or_tape(char *device) { static char * nextproc(FILE *procf) { - static char devname[120]; - char line[100], ptname[100]; - int ma, mi, sz; + static char devname[256]; + char line[1024], ptname[128]; + int ma, mi; + unsigned long long sz; if (procf == NULL) return NULL; while (fgets(line, sizeof(line), procf) != NULL) { - if (sscanf (line, " %d %d %d %[^\n ]", + if (sscanf (line, " %d %d %llu %128[^\n ]", &ma, &mi, &sz, ptname) != 4) continue; snprintf(devname, sizeof(devname), "/dev/%s", ptname); |