Disable "DEBUG" in this file, thus making it so that ped_malloc
no longer initializes all just-allocated memory to all '1' bits.
Given the two bugs I've just fixed, this change is long overdue.

Signed-off-by: Jim Meyering <[EMAIL PROTECTED]>
---
 libparted/libparted.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/libparted/libparted.c b/libparted/libparted.c
index b1a6201..e70f187 100644
--- a/libparted/libparted.c
+++ b/libparted/libparted.c
@@ -52,6 +52,10 @@ typedef struct
     size_t     size;
 } pointer_size_type;

+/* IMHO, none of the DEBUG-related code below is useful, and the
+   ped_malloc memset code is actually quite harmful: it masked at
+   least two nasty bugs that were fixed in June of 2007.  */
+#undef DEBUG
 #ifdef DEBUG
 static pointer_size_type dodgy_malloc_list[] = {
  {0,           0},
@@ -340,4 +344,3 @@ ped_free (void* ptr)

        free (ptr);
 }
-

_______________________________________________
parted-devel mailing list
[email protected]
http://lists.alioth.debian.org/mailman/listinfo/parted-devel

Reply via email to