From f3a08f68124401a4bc3a354b871044c547b73d36 Mon Sep 17 00:00:00 2001 From: Thomas Schmitt Date: Thu, 1 Feb 2007 16:33:27 +0000 Subject: [PATCH] Reacted on justified compiler warning about unitialized sessions variable --- cdrskin/cdrskin.c | 7 ++++++- cdrskin/cdrskin_timestamp.h | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/cdrskin/cdrskin.c b/cdrskin/cdrskin.c index e151b01..32c9b36 100644 --- a/cdrskin/cdrskin.c +++ b/cdrskin/cdrskin.c @@ -3477,7 +3477,7 @@ int Cdrskin_msinfo(struct CdrskiN *skin, int flag) enum burn_disc_status s; struct burn_drive *drive; struct burn_disc *disc= NULL; - struct burn_session **sessions; + struct burn_session **sessions= NULL; struct burn_track **tracks; struct burn_toc_entry toc_entry; @@ -3529,6 +3529,11 @@ int Cdrskin_msinfo(struct CdrskiN *skin, int flag) obtain_nwa:; ret= Cdrskin_obtain_nwa(skin,&nwa,flag); if(ret<=0) { + if (sessions == NULL) { + fprintf(stderr, + "cdrskin: SORRY : Cannot obtain next writeable address\n"); + {ret= 0; goto ex;} + } fprintf(stderr, "cdrskin: NOTE : Guessing next writeable address from leadout\n"); burn_session_get_leadout_entry(sessions[num_sessions-1],&toc_entry); diff --git a/cdrskin/cdrskin_timestamp.h b/cdrskin/cdrskin_timestamp.h index a67ea00..9d2e3d6 100644 --- a/cdrskin/cdrskin_timestamp.h +++ b/cdrskin/cdrskin_timestamp.h @@ -1 +1 @@ -#define Cdrskin_timestamP "2007.02.01.161634" +#define Cdrskin_timestamP "2007.02.01.163511"