Rejecting unformattable BD-R more early

This commit is contained in:
Thomas Schmitt 2008-12-11 07:23:29 +00:00
parent 92d1064e2a
commit 5560e20f8a
3 changed files with 19 additions and 6 deletions

View File

@ -1 +1 @@
#define Cdrskin_timestamP "2008.12.10.114241" #define Cdrskin_timestamP "2008.12.11.072308"

View File

@ -376,7 +376,7 @@ static void *format_worker_func(struct w_list *w)
void burn_disc_format(struct burn_drive *drive, off_t size, int flag) void burn_disc_format(struct burn_drive *drive, off_t size, int flag)
{ {
struct format_opts o; struct format_opts o;
int ok = 0; int ok = 0, ret;
char msg[160]; char msg[160];
if ((SCAN_GOING()) || find_worker(drive) != NULL) { if ((SCAN_GOING()) || find_worker(drive) != NULL) {
@ -411,11 +411,23 @@ void burn_disc_format(struct burn_drive *drive, off_t size, int flag)
ok = 1; /* DVD-RAM */ ok = 1; /* DVD-RAM */
} else if (drive->current_profile == 0x41) { } else if (drive->current_profile == 0x41) {
/* >>> BD-R SRM */ /* BD-R SRM */
ok= 1; ok= 1;
/* >>> check whether already formatted */; ret = drive->read_format_capacities(drive, 0x00);
if (ret > 0 &&
drive->format_descr_type == BURN_FORMAT_IS_FORMATTED)
ok = 0;
if (drive->status != BURN_DISC_BLANK)
ok = 0;
if (!ok) {
libdax_msgs_submit(libdax_messenger,
drive->global_index, 0x00020129,
LIBDAX_MSGS_SEV_SORRY, LIBDAX_MSGS_PRIO_HIGH,
"BD-R not unformatted blank any more. Cannot format.",
0, 0);
drive->cancel = 1;
return;
}
} else if (drive->current_profile == 0x43) { } else if (drive->current_profile == 0x43) {
ok = 1; /* BD-RE */ ok = 1; /* BD-RE */
} }

View File

@ -534,6 +534,7 @@ Range "scdbackup" : 0x00020000 to 0x0002ffff
0x0002015f (MISHAP,HIGH) = Damaged CD table-of-content detected and truncated 0x0002015f (MISHAP,HIGH) = Damaged CD table-of-content detected and truncated
0x00020160 (WARNING,HIGH) = Session without leadout encountered 0x00020160 (WARNING,HIGH) = Session without leadout encountered
0x00020161 (WARNING,HIGH) = Empty session deleted 0x00020161 (WARNING,HIGH) = Empty session deleted
0x00020162 (SORRY, HIG) = BD-R not unformatted blank any more. Cannot format.
libdax_audioxtr: libdax_audioxtr:
0x00020200 (SORRY,HIGH) = Cannot open audio source file 0x00020200 (SORRY,HIGH) = Cannot open audio source file