$NetBSD: patch-aa,v 1.2 2001/04/18 15:57:26 zuntum Exp $ --- lib/aviplay/audio.cpp.orig Fri Dec 15 07:53:05 2000 +++ lib/aviplay/audio.cpp @@ -28,7 +28,11 @@ #include -#include +#ifdef __NetBSD__ +#include +#else + #include +#endif #include "aviplay_impl.h" #include "audio.h" @@ -112,7 +116,7 @@ int audio_queue::write(int fd)//writes some data { int startpos, size, tmp; -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__NetBSD__) const int AUDIO_BUFFER_SIZE=2048; #else const int AUDIO_BUFFER_SIZE=8192; @@ -372,7 +376,7 @@ audio_fd=-1; try { - audio_fd=open("/dev/dsp",O_RDWR|O_NDELAY); + audio_fd=open("/dev/sound",O_RDWR|O_NDELAY); if(audio_fd<=0) throw FATAL("Can't open audio device"); if(audio_fd>0) @@ -388,7 +392,7 @@ catch(FatalError&) { if(audio_fd>0)::close(audio_fd); - audio_fd=open("/dev/dsp", O_RDWR); + audio_fd=open("/dev/sound", O_RDWR); } if(audio_fd<=0) throw FATAL("Can't open audio device");