[Xfce4-commits] r29160 - xfce4-mixer/branches/xfce_4_4/lib
Danny Milosavljevic
dannym at xfce.org
Sun Jan 11 16:54:13 CET 2009
Author: dannym
Date: 2009-01-11 15:54:13 +0000 (Sun, 11 Jan 2009)
New Revision: 29160
Modified:
xfce4-mixer/branches/xfce_4_4/lib/vc_alsa.c
Log:
fix bug# 3680.
Modified: xfce4-mixer/branches/xfce_4_4/lib/vc_alsa.c
===================================================================
--- xfce4-mixer/branches/xfce_4_4/lib/vc_alsa.c 2009-01-11 15:22:19 UTC (rev 29159)
+++ xfce4-mixer/branches/xfce_4_4/lib/vc_alsa.c 2009-01-11 15:54:13 UTC (rev 29160)
@@ -135,14 +135,14 @@
}
if ((err = snd_mixer_attach(handle, card)) < 0) {
- error(_("alsa: Mixer attach %s error: %s\n"), card, snd_strerror(err));
+ error(_("alsa: snd_mixer_attach(\"%s\"): error: %s\n"), card, snd_strerror(err));
snd_mixer_close(handle); /* <-- alsa 0.9.3a fails assert(hctl) if I do that... weeeeird... */
handle = NULL;
return;
}
if ((err = snd_mixer_selem_register(handle, NULL, NULL)) < 0) {
#ifdef DEBUG
- error(_("alsa: Mixer register error: %s\n"), snd_strerror(err));
+ error(_("alsa: snd_mixer_selem_register(...): error: %s\n"), snd_strerror(err));
#endif
snd_mixer_close(handle);
handle = NULL;
@@ -614,7 +614,7 @@
}
}
- stringlist_free (g);
+ vc_free_choices (g);
}
static gchar *vc_get_select(char const *which)
@@ -622,7 +622,8 @@
gint j;
unsigned int jj;
GList *g;
- gchar *s;
+ volchoice_t* item;
+
snd_mixer_elem_t *xelem = NULL;
if (handle == NULL) {
return NULL;
@@ -643,13 +644,15 @@
if (!g)
return NULL;
- s = (gchar *) g_list_nth_data (g, j);
+ item = (volchoice_t *) g_list_nth_data (g, j);
- if (!s)
+ if (!item) {
+ vc_free_choices (g);
return NULL;
+ }
- s = g_strdup (s);
- stringlist_free (g);
+ s = g_strdup (item->name);
+ vc_free_choices (g);
return s;
}
More information about the Xfce4-commits
mailing list