[xiph-commits] r16848 - trunk/ao/src/plugins/oss

xiphmont at svn.xiph.org xiphmont at svn.xiph.org
Fri Jan 29 02:58:31 PST 2010


Author: xiphmont
Date: 2010-01-29 02:58:31 -0800 (Fri, 29 Jan 2010)
New Revision: 16848

Modified:
   trunk/ao/src/plugins/oss/ao_oss.c
Log:
Fixes #604; OSS compat in *BSD isn't perfect, SNDCTL_DSP_GETBLKSIZE is 
slightly incompatible


Modified: trunk/ao/src/plugins/oss/ao_oss.c
===================================================================
--- trunk/ao/src/plugins/oss/ao_oss.c	2010-01-29 10:13:07 UTC (rev 16847)
+++ trunk/ao/src/plugins/oss/ao_oss.c	2010-01-29 10:58:31 UTC (rev 16848)
@@ -272,9 +272,14 @@
 				&(internal->buf_size)) < 0) ||
 			internal->buf_size<=0 )
 	{
-		aerror("cannot get buffer size for "
-                        " device\n");
-		goto ERR;
+          /* Some versions of the *BSD OSS drivers use a subtly
+             different SNDCTL_DSP_GETBLKSIZE ioctl implementation
+             which is, oddly, incompatible with the shipped
+             declaration in soundcard.h.  This ioctl isn't necessary
+             anyway, it's just tuning.  Soldier on without, */
+
+          adebug("cannot get buffer size for device; using a default of 1024kB\n");
+          internal->buf_size=1024;
 	}
 
         /* limited to stereo */



More information about the commits mailing list