next bunch of fixes for bugs found by randconfig
[oweals/busybox.git] / util-linux / fdisk_sgi.c
index 9d444c0be50029a34d4c8e90735b578d7aeb10f5..d8acd6bc736e9354c383ac6d0f55b65b3bfa804f 100644 (file)
@@ -1,4 +1,4 @@
-#ifdef CONFIG_FEATURE_SGI_LABEL
+#if ENABLE_FEATURE_SGI_LABEL
 
 /*
  * Copyright (C) Andreas Neuper, Sep 1998.
@@ -84,10 +84,8 @@ typedef struct {
 #define SGI_INFO_MAGIC          0x00072959
 #define SGI_INFO_MAGIC_SWAPPED  0x59290700
 
-#define SGI_SSWAP16(x) (sgi_other_endian ? __swap16(x) \
-                                : (uint16_t)(x))
-#define SGI_SSWAP32(x) (sgi_other_endian ? __swap32(x) \
-                                : (uint32_t)(x))
+#define SGI_SSWAP16(x) (sgi_other_endian ? fdisk_swap16(x) : (uint16_t)(x))
+#define SGI_SSWAP32(x) (sgi_other_endian ? fdisk_swap32(x) : (uint32_t)(x))
 
 #define sgilabel ((sgi_partition *)MBRbuffer)
 #define sgiparam (sgilabel->devparam)
@@ -753,7 +751,7 @@ sgi_add_partition(int n, int sys)
        sgi_set_partition(n, first, last-first, sys);
 }
 
-#ifdef CONFIG_FEATURE_FDISK_ADVANCED
+#if ENABLE_FEATURE_FDISK_ADVANCED
 static void
 create_sgilabel(void)
 {
@@ -863,7 +861,7 @@ sgi_set_xcyl(void)
 {
        /* do nothing in the beginning */
 }
-#endif /* CONFIG_FEATURE_FDISK_ADVANCED */
+#endif /* FEATURE_FDISK_ADVANCED */
 
 /* _____________________________________________________________
  */