From cc7548f1c73c76f05ad18f0d7a700cf0418a1834 Mon Sep 17 00:00:00 2001 From: Thomas Schmitt Date: Sat, 29 May 2010 07:44:41 +0000 Subject: [PATCH] Bug fix: SIGSEGV of libcdio system adapter if drive list is empty --- cdrskin/cdrskin_timestamp.h | 2 +- libburn/sg-libcdio.c | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/cdrskin/cdrskin_timestamp.h b/cdrskin/cdrskin_timestamp.h index 427e77e..5ccf71d 100644 --- a/cdrskin/cdrskin_timestamp.h +++ b/cdrskin/cdrskin_timestamp.h @@ -1 +1 @@ -#define Cdrskin_timestamP "2010.05.16.090624" +#define Cdrskin_timestamP "2010.05.29.074318" diff --git a/libburn/sg-libcdio.c b/libburn/sg-libcdio.c index bc69401..3234b13 100644 --- a/libburn/sg-libcdio.c +++ b/libburn/sg-libcdio.c @@ -229,8 +229,9 @@ static int sg_give_next_adr_raw(burn_drive_enumerator_t *idx, } } else if (initialize == -1) { - if (*(idx->ppsz_cd_drives) != NULL) - cdio_free_device_list(idx->ppsz_cd_drives); + if (idx->ppsz_cd_drives != NULL) + if (*(idx->ppsz_cd_drives) != NULL) + cdio_free_device_list(idx->ppsz_cd_drives); idx->ppsz_cd_drives = NULL; }