summaryrefslogtreecommitdiff
path: root/audio/mpg123/patches/patch-ac
blob: b10249a09475eb0502c965ba73bf287693f32127 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
$NetBSD: patch-ac,v 1.1 1998/08/15 10:58:41 frueauf Exp $

--- audio_sun.c.orig	Mon Jan  5 12:41:31 1998
+++ audio_sun.c	Sat Aug 15 12:15:25 1998
@@ -17,6 +17,8 @@
 
 #include "mpg123.h"
 
+extern int outburst;
+
 #include <sys/filio.h>
 #ifdef SUNOS
 #include <sun/audioio.h>
@@ -74,6 +76,13 @@
   }
 
 #ifndef NETBSD
+  AUDIO_INITINFO(&ainfo);
+  if(ioctl(ai->fn, AUDIO_GETINFO, &ainfo) == -1)
+    return -1;
+  outburst = ainfo.blocksize;
+  if(outburst > MAXOUTBURST)
+    outburst = MAXOUTBURST;
+
   AUDIO_INITINFO(&ainfo);
 
   switch(ai->output) {