diff src/mediastreamer/osscard.c @ 12029:1c771536a032

[gaim-migrate @ 14322] This _compiles_ for me now. Theres still a bunch of "dereferencing type-punned pointer will break strict-aliasing rules" warning and some redefinition warnings from the various config.h's. The deferencing warnings look like a BE<->LE hack but I left them untouched for the time being. committer: Tailor Script <tailor@pidgin.im>
author Gary Kramlich <grim@reaperworld.com>
date Wed, 09 Nov 2005 09:57:33 +0000
parents e67993da8a22
children
line wrap: on
line diff
--- a/src/mediastreamer/osscard.c	Wed Nov 09 09:02:43 2005 +0000
+++ b/src/mediastreamer/osscard.c	Wed Nov 09 09:57:33 2005 +0000
@@ -23,6 +23,9 @@
 #include "msossread.h"
 #include "msosswrite.h"
 
+#include <sys/ioctl.h>
+#include <unistd.h>
+
 #ifdef HAVE_SYS_SOUNDCARD_H
 #include <sys/soundcard.h>
 
@@ -227,7 +230,6 @@
 
 void oss_card_close(OssCard *obj)
 {
-	int i;
 	obj->ref--;
 	if (obj->ref==0) {
 		close(obj->fd);
@@ -342,7 +344,7 @@
 {
 	int p=0,mix_fd;
 	int osscmd;
-	g_return_if_fail(obj->mixdev_name!=NULL);
+	g_return_val_if_fail(obj->mixdev_name!=NULL, -1);
 #ifdef HAVE_SYS_SOUNDCARD_H
 	switch(way){
 		case SND_CARD_LEVEL_GENERAL: