From 6e17c59f6be4498113686b501b33191971a51435 Mon Sep 17 00:00:00 2001 From: Thomas Schmitt Date: Sat, 27 Mar 2010 15:58:05 +0000 Subject: [PATCH] Avoiding to inquire NWA of unwritable media or states --- cdrskin/cdrskin_timestamp.h | 2 +- libburn/mmc.c | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/cdrskin/cdrskin_timestamp.h b/cdrskin/cdrskin_timestamp.h index a8313c8..510590f 100644 --- a/cdrskin/cdrskin_timestamp.h +++ b/cdrskin/cdrskin_timestamp.h @@ -1 +1 @@ -#define Cdrskin_timestamP "2010.03.26.083158" +#define Cdrskin_timestamP "2010.03.27.155659" diff --git a/libburn/mmc.c b/libburn/mmc.c index 498d5ad..ccb36c4 100644 --- a/libburn/mmc.c +++ b/libburn/mmc.c @@ -425,6 +425,10 @@ int mmc_get_nwa(struct burn_drive *d, int trackno, int *lba, int *nwa) if (mmc_function_spy(d, "mmc_get_nwa") <= 0) return -1; + /* ts B00327 : Avoid to inquire unsuitable media states */ + if (d->status != BURN_DISC_BLANK && d->status != BURN_DISC_APPENDABLE) + return 0; + ret = mmc_read_track_info(d, trackno, &buf, alloc_len); if (ret <= 0) return ret;