[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH parted 7/7] dasd: Fix NULL pointer dereference in dasd_read
From: |
Hans de Goede |
Subject: |
[PATCH parted 7/7] dasd: Fix NULL pointer dereference in dasd_read |
Date: |
Wed, 10 Feb 2010 14:13:01 +0100 |
* libparted/labels/dasd.c (dasd_read): Fix NULL ptr dereference.
---
libparted/labels/dasd.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/libparted/labels/dasd.c b/libparted/labels/dasd.c
index 4b5840b..516d189 100644
--- a/libparted/labels/dasd.c
+++ b/libparted/labels/dasd.c
@@ -399,7 +399,7 @@ dasd_read (PedDisk* disk)
if (strncmp(PART_TYPE_SWAP, str, 6) == 0) {
fs = ped_file_system_probe(&part->geom);
- if (is_linux_swap(fs->name)) {
+ if (fs && is_linux_swap(fs->name)) {
dasd_data->system = PARTITION_LINUX_SWAP;
PDEBUG;
}
--
1.6.6
- [PATCH parted 1/7] linux: Fixup phys_sector_size setting, Hans de Goede, 2010/02/10
- [PATCH parted 3/7] linux: handle incomplete topology information, Hans de Goede, 2010/02/10
- [PATCH parted 6/7] parted: Change default alignment to optimal, Hans de Goede, 2010/02/10
- [PATCH parted 4/7] parted: Honor --align option also in mkpartfs, resize and print cmds, Hans de Goede, 2010/02/10
- [PATCH parted 7/7] dasd: Fix NULL pointer dereference in dasd_read,
Hans de Goede <=
- [PATCH parted 5/7] parted: change warnings when initial constrained mkpart fails, Hans de Goede, 2010/02/10
- [PATCH parted 2/7] libparted: Give device_get_*_alignment sane defaults, Hans de Goede, 2010/02/10
- Re: [PATCH parted 1/7] linux: Fixup phys_sector_size setting, Jim Meyering, 2010/02/10