]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - snd_bsd.c
Move a part of r_refdef_t into a new r_refdef_scene_t struct and refactor the code...
[xonotic/darkplaces.git] / snd_bsd.c
index adb28d8fb6c8eb3d78867a5f6471157fddeee240..0dd7186a19ef0cae7ddcfc67243b0af8cccf5153 100644 (file)
--- a/snd_bsd.c
+++ b/snd_bsd.c
@@ -17,6 +17,7 @@ along with this program; if not, write to the Free Software
 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
 
 */
+#include "quakedef.h"
 
 #include <sys/param.h>
 #include <sys/audioio.h>
@@ -31,7 +32,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
 #endif
 #include <unistd.h>
 
-#include "quakedef.h"
 #include "snd_main.h"
 
 
@@ -160,9 +160,9 @@ void SndSys_Submit (void)
 
                snd_renderbuffer->startframe += written / factor;
 
-               if ((unsigned int)written < nbframes * factor)
+               if ((unsigned int)written < limit * factor)
                {
-                       Con_Printf("SndSys_Submit: audio can't keep up! (%d < %u)\n", written, nbframes * factor);
+                       Con_Printf("SndSys_Submit: audio can't keep up! (%u < %u)\n", written, limit * factor);
                        return;
                }