From bb9ef6b988ca7581658840d209ef1c8d87dfa5b4 Mon Sep 17 00:00:00 2001 From: Thomas Schmitt Date: Thu, 27 Nov 2008 17:21:54 +0000 Subject: [PATCH] Changed error severity with TOC truncation to MISHAP --- cdrskin/cdrskin_timestamp.h | 2 +- libburn/libdax_msgs.h | 2 +- libburn/structure.c | 25 +++++++++++++++++-------- 3 files changed, 19 insertions(+), 10 deletions(-) diff --git a/cdrskin/cdrskin_timestamp.h b/cdrskin/cdrskin_timestamp.h index 12f5410..57f5e96 100644 --- a/cdrskin/cdrskin_timestamp.h +++ b/cdrskin/cdrskin_timestamp.h @@ -1 +1 @@ -#define Cdrskin_timestamP "2008.11.27.081027" +#define Cdrskin_timestamP "2008.11.27.172124" diff --git a/libburn/libdax_msgs.h b/libburn/libdax_msgs.h index 2a809a8..4f81d33 100644 --- a/libburn/libdax_msgs.h +++ b/libburn/libdax_msgs.h @@ -531,7 +531,7 @@ Range "scdbackup" : 0x00020000 to 0x0002ffff 0x0002015c (FAILURE,HIGH) = Fifo size is smaller than desired peek buffer 0x0002015d (FAILURE,HIGH) = Fifo input ended short of desired peek buffer size 0x0002015e (FATAL,HIGH) = Fifo is already under consumption when peeking - 0x0002015f (FAILURE,HIGH) = Damaged CD table-of-content detected and truncated + 0x0002015f (MISHAP,HIGH) = Damaged CD table-of-content detected and truncated libdax_audioxtr: 0x00020200 (SORRY,HIGH) = Cannot open audio source file diff --git a/libburn/structure.c b/libburn/structure.c index 1b2360e..21f3a33 100644 --- a/libburn/structure.c +++ b/libburn/structure.c @@ -532,7 +532,7 @@ int burn_disc_cd_toc_extensions(struct burn_disc *d, int flag) int sidx= 0, tidx= 0; struct burn_toc_entry *entry, *prev_entry= NULL; - /* ts A81126 : ticket 146 : There is a SIGSIGV in here */ + /* ts A81126 : ticket 146 : There is a SIGSEGV in here */ char msg_data[321], *msg; strcpy(msg_data, @@ -554,6 +554,14 @@ int burn_disc_cd_toc_extensions(struct burn_disc *d, int flag) sidx, d->sessions); goto failure; } + /* ts A81126 : ticket 146 : + This is the main suspect for the SIGSEGV */ + if (d->session[sidx]->leadout_entry == NULL) { + sprintf(msg, + " Session %d of %d: Leadout entry missing.", + sidx, d->sessions); + goto failure; + } for (tidx = 0; tidx < d->session[sidx]->tracks + 1; tidx++) { if (tidx < d->session[sidx]->tracks) { if (d->session[sidx]->track[tidx] == NULL) { @@ -563,14 +571,15 @@ int burn_disc_cd_toc_extensions(struct burn_disc *d, int flag) goto failure; } entry = d->session[sidx]->track[tidx]->entry; + if (entry == NULL) { + sprintf(msg, + "session %d of %d, track %d of %d, entry == NULL", + sidx, d->sessions, tidx, + d->session[sidx]->tracks); + goto failure; + } } else entry = d->session[sidx]->leadout_entry; - if (entry == NULL) { - sprintf(msg, - "session %d of %d, track %d of %d, entry == NULL", - sidx, d->sessions, tidx, d->session[sidx]->tracks); - goto failure; - } entry->session_msb = 0; entry->point_msb = 0; entry->start_lba = burn_msf_to_lba(entry->pmin, @@ -593,7 +602,7 @@ int burn_disc_cd_toc_extensions(struct burn_disc *d, int flag) return 1; failure: libdax_msgs_submit(libdax_messenger, -1, 0x0002015f, - LIBDAX_MSGS_SEV_FAILURE, LIBDAX_MSGS_PRIO_HIGH, msg_data, 0, 0); + LIBDAX_MSGS_SEV_MISHAP, LIBDAX_MSGS_PRIO_HIGH, msg_data, 0, 0); d->sessions= sidx; return 0; }