Allow more freedom in specifying access mode.
Image drivers now have an "image" access mode.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
$Id: cdrdao.c,v 1.6 2004/05/11 02:16:00 rocky Exp $
|
||||
$Id: cdrdao.c,v 1.7 2004/05/13 01:50:24 rocky Exp $
|
||||
|
||||
Copyright (C) 2004 Rocky Bernstein <rocky@panix.com>
|
||||
toc reading routine adapted from cuetools
|
||||
@@ -25,7 +25,7 @@
|
||||
(*.cue).
|
||||
*/
|
||||
|
||||
static const char _rcsid[] = "$Id: cdrdao.c,v 1.6 2004/05/11 02:16:00 rocky Exp $";
|
||||
static const char _rcsid[] = "$Id: cdrdao.c,v 1.7 2004/05/13 01:50:24 rocky Exp $";
|
||||
|
||||
#include "cdio_assert.h"
|
||||
#include "cdio_private.h"
|
||||
@@ -1054,6 +1054,8 @@ _get_arg_cdrdao (void *env, const char key[])
|
||||
return _obj->tocent[0].filename;
|
||||
} else if (!strcmp (key, "toc")) {
|
||||
return _obj->toc_name;
|
||||
} else if (!strcmp(key, "access-mode")) {
|
||||
return "image";
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
@@ -1200,8 +1202,8 @@ cdio_is_tocfile(const char *toc_name)
|
||||
CdIo *
|
||||
cdio_open_am_cdrdao (const char *psz_source_name, const char *psz_access_mode)
|
||||
{
|
||||
if (psz_access_mode != NULL)
|
||||
cdio_warn ("there is only one access mode for toc. Arg %s ignored",
|
||||
if (psz_access_mode != NULL && strcmp(psz_access_mode, "image"))
|
||||
cdio_warn ("there is only one access mode, 'image' for toc. Arg %s ignored",
|
||||
psz_access_mode);
|
||||
return cdio_open_cdrdao(psz_source_name);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user