changeset 2022:c6023e5efd06

warning fixes
author William Pitcock <nenolod@atheme.org>
date Thu, 11 Oct 2007 15:19:28 -0500
parents 72c60094ad0a
children 27239c2e3b47
files src/alsa/audio.c src/alsa/configure.c
diffstat 2 files changed, 6 insertions(+), 11 deletions(-) [+]
line wrap: on
line diff
--- a/src/alsa/audio.c	Thu Oct 11 15:13:59 2007 -0500
+++ b/src/alsa/audio.c	Thu Oct 11 15:19:28 2007 -0500
@@ -141,7 +141,7 @@
 	/* if debug mode is enabled, dump ALSA state to console */
 	if (alsa_cfg.debug)
 	{
-		snd_pcm_status_t *alsa_status;
+		snd_pcm_status_t *alsa_status = NULL;
 		snd_pcm_status_alloca(&alsa_status);
 		if (snd_pcm_status(alsa_pcm, alsa_status) < 0)
 			g_warning("xrun_recover(): snd_pcm_status() failed");
@@ -587,11 +587,6 @@
  */
 static void alsa_do_write(gpointer data, int length)
 {
-	EffectPlugin *ep = NULL;
-	int new_freq;
-	int new_chn;
-	AFormat f;
-
 	if (paused)
 		return;
 
@@ -826,8 +821,8 @@
 static int alsa_setup(struct snd_format *f)
 {
 	int err;
-	snd_pcm_hw_params_t *hwparams;
-	snd_pcm_sw_params_t *swparams;
+	snd_pcm_hw_params_t *hwparams = NULL;
+	snd_pcm_sw_params_t *swparams = NULL;
 	unsigned int alsa_buffer_time, alsa_period_time;
 	snd_pcm_uframes_t alsa_buffer_size, alsa_period_size;
 
@@ -859,12 +854,12 @@
 
 	if (alsa_cfg.debug)
 	{
-		snd_pcm_info_t *info;
+		snd_pcm_info_t *info = NULL;
 		int alsa_card, alsa_device, alsa_subdevice;
 
 		snd_pcm_info_alloca(&info);
 		snd_pcm_info(alsa_pcm, info);
-		alsa_card =  snd_pcm_info_get_card(info);
+		alsa_card = snd_pcm_info_get_card(info);
 		alsa_device = snd_pcm_info_get_device(info);
 		alsa_subdevice = snd_pcm_info_get_subdevice(info);
 		printf("Card %i, Device %i, Subdevice %i\n",
--- a/src/alsa/configure.c	Thu Oct 11 15:13:59 2007 -0500
+++ b/src/alsa/configure.c	Thu Oct 11 15:19:28 2007 -0500
@@ -128,7 +128,7 @@
 {
 	GtkWidget *item;
 	int pcm_device = -1, err;
-	snd_pcm_info_t *pcm_info;
+	snd_pcm_info_t *pcm_info = NULL;
 	snd_ctl_t *ctl;
 	char dev[64], *card_name;