diff options
author | Alexander Nedotsukov <bland@FreeBSD.org> | 2004-12-11 16:58:20 +0000 |
---|---|---|
committer | Alexander Nedotsukov <bland@FreeBSD.org> | 2004-12-11 16:58:20 +0000 |
commit | 48f37eba9d60c2a3246f45ed3a1dcd0c59ce9f28 (patch) | |
tree | 65a1ddd458267c61512ec30e6472755761ef074c /audio/sound-juicer/files | |
parent | db54004d50f9394a1d327c7eb7059c13ae808b77 (diff) |
Notes
Diffstat (limited to 'audio/sound-juicer/files')
-rw-r--r-- | audio/sound-juicer/files/patch-src::cd-drive.c | 31 |
1 files changed, 16 insertions, 15 deletions
diff --git a/audio/sound-juicer/files/patch-src::cd-drive.c b/audio/sound-juicer/files/patch-src::cd-drive.c index 690b0953e199..56d594fb962f 100644 --- a/audio/sound-juicer/files/patch-src::cd-drive.c +++ b/audio/sound-juicer/files/patch-src::cd-drive.c @@ -1,10 +1,10 @@ ---- src/cd-drive.c.orig Tue Sep 28 23:37:37 2004 -+++ src/cd-drive.c Wed Nov 10 22:37:44 2004 -@@ -578,7 +578,49 @@ +--- src/cd-drive.c.orig Sun Dec 12 01:39:32 2004 ++++ src/cd-drive.c Sun Dec 12 01:41:50 2004 +@@ -596,7 +596,49 @@ #if defined(__linux__) || defined(__FreeBSD__) -+#if !defined(__linux__) ++#if !defined(__linux) +static int +get_device_max_read_speed (char *device) +{ @@ -14,11 +14,11 @@ + + max_speed = -1; + -+ fd = open (device, O_RDONLY|O_EXCL|O_NONBLOCK); ++ fd = open (device, O_RDWR|O_EXCL|O_NONBLOCK); + if (fd < 0) { + return -1; + } -+ + + get_read_write_speed (fd, &read_speed, &write_speed); + close (fd); + max_speed = (int)floor (read_speed) / CD_ROM_SPEED; @@ -26,7 +26,7 @@ + return max_speed; +} +#endif - ++ +static int +get_device_max_write_speed (char *device) +{ @@ -36,7 +36,7 @@ + + max_speed = -1; + -+ fd = open (device, O_RDONLY|O_EXCL|O_NONBLOCK); ++ fd = open (device, O_RDWR|O_EXCL|O_NONBLOCK); + if (fd < 0) { + return -1; + } @@ -50,10 +50,12 @@ #endif /* __linux__ || __FreeBSD__ */ -@@ -782,49 +824,6 @@ +@@ -798,50 +840,6 @@ + } + } return NULL; - } - +-} +- -#if !defined(__linux) -static int -get_device_max_read_speed (char *device) @@ -64,7 +66,7 @@ - - max_speed = -1; - -- fd = open (device, O_RDONLY|O_EXCL|O_NONBLOCK); +- fd = open (device, O_RDWR|O_EXCL|O_NONBLOCK); - if (fd < 0) { - return -1; - } @@ -86,7 +88,7 @@ - - max_speed = -1; - -- fd = open (device, O_RDONLY|O_EXCL|O_NONBLOCK); +- fd = open (device, O_RDWR|O_EXCL|O_NONBLOCK); - if (fd < 0) { - return -1; - } @@ -96,7 +98,6 @@ - max_speed = (int)floor (write_speed) / CD_ROM_SPEED; - - return max_speed; --} + } static char * - get_scsi_cd_name (int bus, int id, int lun, const char *dev, |