← Commit list

99a75d137

Eric Andersen
Eric Andersen
2003-08-08
FAILED Duration: 92s

Subject

Patch from Kent Robotti to being fdisk in sync with v2.12 final.

Binary

No binary (build failed)

Architecture & Compiler Flags

Architecture: x86_64-linux-gnu Compiler: gcc (Ubuntu 11.4.0-1ubuntu1~22.04.3) 11.4.0

—

Build Log

(log yok)

Commit Diff GitHub →

util-linux/fdisk.c+10 -6
@@ -10,7 +10,7 @@
* Vladimir Oleynik <[email protected]> 2001,2002 Busybox port
*/
-#define UTIL_LINUX_VERSION "2.12pre"
+#define UTIL_LINUX_VERSION "2.12"
#define PROC_PARTITIONS "/proc/partitions"
@@ -1925,11 +1925,9 @@ sgi_get_swappartition(void)
static void
sgi_list_table(int xtra) {
- int i, w;
+ int i, w, wd;
int kpi = 0; /* kernel partition ID */
- w = strlen(disk_device);
-
if(xtra) {
printf(_("\nDisk %s (SGI disk label): %d heads, %d sectors\n"
"%d cylinders, %d physical cylinders\n"
@@ -1949,9 +1947,15 @@ sgi_list_table(int xtra) {
disk_device, heads, sectors, cylinders,
str_units(PLURAL), units_per_sector );
}
+
+ w = strlen(disk_device);
+ wd = strlen(_("Device"));
+ if (w < wd)
+ w = wd;
+
printf(_("----- partitions -----\n"
"Pt# %*s Info Start End Sectors Id System\n"),
- w + 1, _("Device"));
+ w + 2, _("Device"));
for (i = 0 ; i < partitions; i++) {
if( sgi_get_num_sectors(i) || debug ) {
uint32_t start = sgi_get_start_sector(i);
@@ -1960,7 +1964,7 @@ sgi_list_table(int xtra) {
printf(
"%2d: %s %4s %9ld %9ld %9ld %2x %s\n",
/* fdisk part number */ i+1,
-/* device */ partname(disk_device, kpi, w+2),
+/* device */ partname(disk_device, kpi, w+3),
/* flags */ (sgi_get_swappartition() == i) ? "swap" :
/* flags */ (sgi_get_bootpartition() == i) ? "boot" : " ",
/* start */ (long) scround(start),