Author: jim
Date: 2006-04-14 18:28:03 -0600 (Fri, 14 Apr 2006)
New Revision: 1480

Added:
   trunk/util-linux/util-linux-2.12r-gcc41_sun_disklabel_fixes-1.patch
Modified:
   trunk/
Log:
 [EMAIL PROTECTED]:  jim | 2006-04-14 17:26:08 -0700
 Added: util-linux-2.12r-gcc41_sun_disklabel_fixes-1.patch



Property changes on: trunk
___________________________________________________________________
Name: svk:merge
   - cc2644d5-6cf8-0310-b111-c40428001e49:/patches:1710
e59974df-c20a-0410-b7e1-d7eaf1be8828:/patches:1585
   + cc2644d5-6cf8-0310-b111-c40428001e49:/patches:1710
e59974df-c20a-0410-b7e1-d7eaf1be8828:/patches:1589

Added: trunk/util-linux/util-linux-2.12r-gcc41_sun_disklabel_fixes-1.patch
===================================================================
--- trunk/util-linux/util-linux-2.12r-gcc41_sun_disklabel_fixes-1.patch         
                (rev 0)
+++ trunk/util-linux/util-linux-2.12r-gcc41_sun_disklabel_fixes-1.patch 
2006-04-15 00:28:03 UTC (rev 1480)
@@ -0,0 +1,28 @@
+Submitted By: Joe Ciccone <joeciccone at crazyeyesoft dot com>
+Date: 2006-04-14
+Initial Package Version: 2.12r
+Upstream Status: Sent
+Origin: Joe Ciccone
+Description: This patch fixes fdisk so that it can properly calculate the
+             checksum of a sun disklabel.
+
+--- util-linux-2.12r.orig/fdisk/fdisksunlabel.c        2004-12-22 
10:36:24.000000000 -0500
++++ util-linux-2.12r/fdisk/fdisksunlabel.c     2006-04-14 17:50:53.000000000 
-0400
+@@ -118,7 +118,7 @@
+ int
+ check_sun_label(void) {
+       unsigned short *ush;
+-      int csum;
++      int csum = 0;
+ 
+       if (sunlabel->magic != SUN_LABEL_MAGIC &&
+           sunlabel->magic != SUN_LABEL_MAGIC_SWAPPED) {
+@@ -128,7 +128,7 @@
+       }
+       other_endian = (sunlabel->magic == SUN_LABEL_MAGIC_SWAPPED);
+       ush = ((unsigned short *) (sunlabel + 1)) - 1;
+-      for (csum = 0; ush >= (unsigned short *)sunlabel;) csum ^= *ush--;
++      while (ush < (unsigned short *)sunlabel) csum ^= *ush--;
+       if (csum) {
+               fprintf(stderr,_("Detected sun disklabel with wrong checksum.\n"
+                               "Probably you'll have to set all the values,\n"

-- 
http://linuxfromscratch.org/mailman/listinfo/patches
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page

Reply via email to