[parted-devel] Minor change: remove type-cast from ped_disk_type_register
Debarshi 'Rishi' Ray
debarshi.ray at gmail.com
Thu Nov 1 12:41:33 UTC 2007
Were the type-casts necessary?
diff --git a/libparted/disk.c b/libparted/disk.c
index e2e55c3..d8a85f4 100644
--- a/libparted/disk.c
+++ b/libparted/disk.c
@@ -68,9 +68,8 @@ ped_disk_type_register (PedDiskType* dis
PED_ASSERT (disk_type->ops != NULL, return);
PED_ASSERT (disk_type->name != NULL, return);
- /* pretend that "next" isn't part of the struct :-) */
- ((struct _PedDiskType*) disk_type)->next = disk_types;
- disk_types = (struct _PedDiskType*) disk_type;
+ disk_type->next = disk_types;
+ disk_types = disk_type;
}
void
Happy hacking,
Debarshi
--
GPG key ID: 63D4A5A7
Key server: pgp.mit.edu
More information about the parted-devel
mailing list