X-Git-Url: http://git.xonotic.org/?a=blobdiff_plain;f=cd_linux.c;h=bc07b849f9febd274d719cdf36a2d3e7ca7699a5;hb=8f47ee7b6e3c66303e5199b42d79dc6d534987cb;hp=2db702cb3f9f2b685ee644377b51e49c997a4fea;hpb=41f1138b4a171ebb11be1418ed5579a8935b5516;p=xonotic%2Fdarkplaces.git diff --git a/cd_linux.c b/cd_linux.c index 2db702cb..bc07b849 100644 --- a/cd_linux.c +++ b/cd_linux.c @@ -21,7 +21,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. // rights reserved. // suggested by Zero_Dogg to fix a compile problem on Mandriva Linux -#define __KERNEL_STRICT_NAMES +#include "quakedef.h" #include #include @@ -31,7 +31,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include #include -#include "quakedef.h" #include "cdaudio.h" @@ -113,7 +112,7 @@ void CDAudio_SysSetVolume (float volume) } -int CDAudio_SysPlay (unsigned char track) +int CDAudio_SysPlay (int track) { struct cdrom_tocentry entry; struct cdrom_ti ti; @@ -204,7 +203,7 @@ int CDAudio_SysUpdate (void) struct cdrom_subchnl subchnl; static time_t lastchk = 0; - if (cdPlaying && lastchk < time(NULL)) + if (cdPlaying && lastchk < time(NULL) && cdfile != -1) { lastchk = time(NULL) + 2; //two seconds between chks subchnl.cdsc_format = CDROM_MSF;