Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.busybox.net/busybox.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenis Vlasenko <vda.linux@googlemail.com>2007-01-03 05:58:54 +0300
committerDenis Vlasenko <vda.linux@googlemail.com>2007-01-03 05:58:54 +0300
commitd54708399dbab43b2867dad1a41eb199eb0813d8 (patch)
tree28d5d123f2babb30d3998febc250a584d92ca065 /util-linux/fdisk_osf.c
parent9b1381fd2fb7179f731709542507015799f90a51 (diff)
fdisk: remove 8k buffer from bss - OSF labels
are not THAT common anyway
Diffstat (limited to 'util-linux/fdisk_osf.c')
-rw-r--r--util-linux/fdisk_osf.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/util-linux/fdisk_osf.c b/util-linux/fdisk_osf.c
index 17acd1977..16a046ea3 100644
--- a/util-linux/fdisk_osf.c
+++ b/util-linux/fdisk_osf.c
@@ -272,12 +272,9 @@ static struct partition *xbsd_part;
static int xbsd_part_index;
#endif
-#if defined(__alpha__)
/* We access this through a uint64_t * when checksumming */
-static char disklabelbuffer[BSD_BBSIZE] ATTRIBUTE_ALIGNED(8);
-#else
-static char disklabelbuffer[BSD_BBSIZE];
-#endif
+/* hopefully xmalloc gives us required alignment */
+static char *disklabelbuffer; /*[BSD_BBSIZE]*/
static struct xbsd_disklabel xbsd_dlabel;
@@ -299,7 +296,7 @@ check_osf_label(void)
}
static int
-btrydev(const char * dev)
+bsd_trydev(const char * dev)
{
if (xbsd_readlabel(NULL, &xbsd_dlabel) == 0)
return -1;
@@ -309,7 +306,7 @@ btrydev(const char * dev)
}
static void
-bmenu(void)
+bsd_menu(void)
{
puts(_("Command action"));
puts(_("\td\tdelete a BSD partition"));
@@ -431,7 +428,7 @@ bsd_select(void)
break;
#endif
default:
- bmenu();
+ bsd_menu();
break;
}
}
@@ -921,6 +918,9 @@ xbsd_readlabel(struct partition *p, struct xbsd_disklabel *d)
{
int t, sector;
+ if (!disklabelbuffer)
+ disklabelbuffer = xmalloc(BSD_BBSIZE);
+
/* p is used only to get the starting sector */
#if !defined(__alpha__)
sector = (p ? get_start_sect(p) : 0);