[BusyBox-cvs] busybox/util-linux fdisk.c,1.2,1.3
Erik Andersen
andersen at codepoet.org
Wed Dec 11 03:49:37 UTC 2002
Update of /var/cvs/busybox/util-linux
In directory winder:/tmp/cvs-serv9518/util-linux
Modified Files:
fdisk.c
Log Message:
Eliminate dependancy on kernel header files. Naughty naughty.
Using linux kernel headers is a Bad Thing(tm) and should be
punished.
Index: fdisk.c
===================================================================
RCS file: /var/cvs/busybox/util-linux/fdisk.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- fdisk.c 8 Dec 2002 11:51:05 -0000 1.2
+++ fdisk.c 11 Dec 2002 03:49:33 -0000 1.3
@@ -41,15 +41,13 @@
#include <scsi/scsi.h> /* SCSI_IOCTL_GET_IDLUN */
#undef u_char
-#ifdef HAVE_blkpg_h
-#include <linux/blkpg.h>
-#endif
-
#include <sys/ioctl.h>
#include <sys/param.h>
-#include <linux/types.h> /* for __u32, __u16, __u8, __s16 */
[...186 lines suppressed...]
if (sgilabel->directory[i].vol_file_size)
{
- __u32 start = SGI_SSWAP32(sgilabel->directory[i].vol_file_start);
- __u32 len = SGI_SSWAP32(sgilabel->directory[i].vol_file_size);
+ uint32_t start = SGI_SSWAP32(sgilabel->directory[i].vol_file_start);
+ uint32_t len = SGI_SSWAP32(sgilabel->directory[i].vol_file_size);
char*name = sgilabel->directory[i].vol_file_name;
printf(_("%2d: %-10s sector%5u size%8u\n"),
i, name, (unsigned int) start, (unsigned int) len);
@@ -3222,8 +3220,8 @@
w + 1, _("Device"));
for (i = 0 ; i < partitions; i++) {
if (sunlabel->partitions[i].num_sectors) {
- __u32 start = SUN_SSWAP32(sunlabel->partitions[i].start_cylinder) * heads * sectors;
- __u32 len = SUN_SSWAP32(sunlabel->partitions[i].num_sectors);
+ uint32_t start = SUN_SSWAP32(sunlabel->partitions[i].start_cylinder) * heads * sectors;
+ uint32_t len = SUN_SSWAP32(sunlabel->partitions[i].num_sectors);
printf(
"%s %c%c %9ld %9ld %9ld%c %2x %s\n",
/* device */ partname(disk_device, i+1, w),
More information about the busybox-cvs
mailing list