diff --git a/include/cdio/logging.h b/include/cdio/logging.h index 23e54464..2d69fe4b 100644 --- a/include/cdio/logging.h +++ b/include/cdio/logging.h @@ -1,5 +1,5 @@ /* - $Id: logging.h,v 1.7 2004/05/05 01:50:46 rocky Exp $ + $Id: logging.h,v 1.8 2004/05/05 02:47:18 rocky Exp $ Copyright (C) 2000, Herbert Valerio Riedel Copyright (C) 2003, Rocky Bernstein @@ -111,7 +111,7 @@ void cdio_info (const char format[], ...) GNUC_PRINTF(1,2); void cdio_warn (const char format[], ...) GNUC_PRINTF(1,2); /** - * Handle an error message. Execution is terminated + * Handle an error message. Execution is terminated. * * @see cdio_log for a more generic routine. */ diff --git a/lib/FreeBSD/freebsd.h b/lib/FreeBSD/freebsd.h index e4582410..153b839d 100644 --- a/lib/FreeBSD/freebsd.h +++ b/lib/FreeBSD/freebsd.h @@ -1,5 +1,5 @@ /* - $Id: freebsd.h,v 1.2 2004/04/30 21:36:54 rocky Exp $ + $Id: freebsd.h,v 1.3 2004/05/05 02:47:18 rocky Exp $ Copyright (C) 2003, 2004 Rocky Bernstein @@ -32,7 +32,7 @@ #include "cdio_private.h" /* Is this the right default? */ -#define DEFAULT_CDIO_DEVICE "/dev/acd0c" +#define DEFAULT_CDIO_DEVICE "/dev/cd0c" #include diff --git a/lib/FreeBSD/freebsd_cam.c b/lib/FreeBSD/freebsd_cam.c index 310d4cf7..6b0e4dc1 100644 --- a/lib/FreeBSD/freebsd_cam.c +++ b/lib/FreeBSD/freebsd_cam.c @@ -1,5 +1,5 @@ /* - $Id: freebsd_cam.c,v 1.3 2004/05/05 02:39:16 rocky Exp $ + $Id: freebsd_cam.c,v 1.4 2004/05/05 02:47:18 rocky Exp $ Copyright (C) 2004 Rocky Bernstein @@ -26,7 +26,7 @@ # include "config.h" #endif -static const char _rcsid[] = "$Id: freebsd_cam.c,v 1.3 2004/05/05 02:39:16 rocky Exp $"; +static const char _rcsid[] = "$Id: freebsd_cam.c,v 1.4 2004/05/05 02:47:18 rocky Exp $"; #ifdef HAVE_FREEBSD_CDROM @@ -172,7 +172,7 @@ read_mode2_sectors_freebsd_cam (_img_private_t *_obj, void *buf, uint32_t lba, cam_fill_csio (&(_obj->ccb.csio), 1, NULL, CAM_DEV_QFRZDIS, MSG_SIMPLE_Q_TAG, NULL, 0, sizeof(_obj->ccb.csio.sense_data), 0, 30*1000); - _obj->ccb.csio.cdb_len = (8)+1; + _obj->ccb.csio.cdb_len = (b_read_10 ? 8 : 9) + 1; CDIO_MMC_SET_COMMAND(_obj->ccb.csio.cdb_io.cdb_bytes, b_read_10 ? CDIO_MMC_GPCMD_READ_10 : CDIO_MMC_GPCMD_READ_CD); diff --git a/lib/_cdio_linux.c b/lib/_cdio_linux.c index aed338b7..1104472a 100644 --- a/lib/_cdio_linux.c +++ b/lib/_cdio_linux.c @@ -1,5 +1,5 @@ /* - $Id: _cdio_linux.c,v 1.42 2004/05/04 01:57:23 rocky Exp $ + $Id: _cdio_linux.c,v 1.43 2004/05/05 02:47:18 rocky Exp $ Copyright (C) 2001 Herbert Valerio Riedel Copyright (C) 2002, 2003, 2004 Rocky Bernstein @@ -27,7 +27,7 @@ # include "config.h" #endif -static const char _rcsid[] = "$Id: _cdio_linux.c,v 1.42 2004/05/04 01:57:23 rocky Exp $"; +static const char _rcsid[] = "$Id: _cdio_linux.c,v 1.43 2004/05/05 02:47:18 rocky Exp $"; #include @@ -300,24 +300,22 @@ _read_audio_sectors_linux (void *env, void *buf, lsn_t lsn, */ static int _read_packet_mode2_sectors_mmc (int fd, void *buf, lba_t lba, - unsigned int nblocks, bool use_read_10) + unsigned int nblocks, bool b_read_10) { struct cdrom_generic_command cgc; memset (&cgc, 0, sizeof (struct cdrom_generic_command)); - CDIO_MMC_SET_COMMAND(cgc.cmd, - use_read_10 ? GPCMD_READ_10 : CDIO_MMC_GPCMD_READ_CD); + CDIO_MMC_SET_COMMAND(cgc.cmd, b_read_10 + ? CDIO_MMC_GPCMD_READ_10 : CDIO_MMC_GPCMD_READ_CD); CDIO_MMC_SET_READ_LBA(cgc.cmd, lba); CDIO_MMC_SET_READ_LENGTH(cgc.cmd, nblocks); - if (!use_read_10) - { - cgc.cmd[1] = 0; /* sector size mode2 */ - - cgc.cmd[9] = 0x58; /* 2336 mode2 */ - } + if (!b_read_10) { + cgc.cmd[1] = 0; /* sector size mode2 */ + cgc.cmd[9] = 0x58; /* 2336 mode2 */ + } cgc.buflen = M2RAW_SECTOR_SIZE * nblocks; cgc.buffer = buf; @@ -327,7 +325,7 @@ _read_packet_mode2_sectors_mmc (int fd, void *buf, lba_t lba, #endif cgc.data_direction = CGC_DATA_READ; - if (use_read_10) + if (b_read_10) { int retval; @@ -351,7 +349,7 @@ _read_packet_mode2_sectors_mmc (int fd, void *buf, lba_t lba, static int _read_packet_mode2_sectors (int fd, void *buf, lba_t lba, - unsigned int nblocks, bool use_read_10) + unsigned int nblocks, bool b_read_10) { unsigned int l = 0; int retval = 0; @@ -362,7 +360,7 @@ _read_packet_mode2_sectors (int fd, void *buf, lba_t lba, void *buf2 = ((char *)buf ) + (l * M2RAW_SECTOR_SIZE); retval |= _read_packet_mode2_sectors_mmc (fd, buf2, lba + l, nblocks2, - use_read_10); + b_read_10); if (retval) break;