[Xfce4-commits] <xfce4-volumed:master> Releasing 0.1.12 (bugfix only), see Changelog

Steve Dodier noreply at xfce.org
Wed Mar 2 20:32:03 CET 2011


Updating branch refs/heads/master
         to caec4ccd142a961f4a575601eb27857f24062fac (commit)
       from 1cac2a0e63b476d69bc5ad93474776d80f9dbab3 (commit)

commit caec4ccd142a961f4a575601eb27857f24062fac
Author: Steve Dodier <sidnioulz at gmail.com>
Date:   Wed Mar 2 20:30:02 2011 +0100

    Releasing 0.1.12 (bugfix only), see Changelog

 ChangeLog       |    3 +++
 configure.ac    |    2 +-
 src/xvd_mixer.c |    5 ++++-
 3 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 21bbda5..7de69f3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,6 @@
+2011-03-02  Steve Dodier <sidnioulz at gmail.com>
+	* Another check to avoid SIGFPE when calculating average volume (valid card/track but no volume channels)
+
 2010-11-18  Steve Dodier <sidnioulz at gmail.com>
 	* Check for volume channels before getting a GStreamer track's volume (fixes lp #667617)
 
diff --git a/configure.ac b/configure.ac
index 8650a79..49287b6 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,4 +1,4 @@
-AC_INIT([xfce4-volumed], [0.1.11], [http://bugs.launchpad.net/xfce4-volumed])
+AC_INIT([xfce4-volumed], [0.1.12], [http://bugs.launchpad.net/xfce4-volumed])
 AM_INIT_AUTOMAKE([AC_PACKAGE_TARNAME()], [AC_PACKAGE_VERSION()])
 
 AC_CONFIG_SRCDIR([src/main.c])
diff --git a/src/xvd_mixer.c b/src/xvd_mixer.c
index cd7c006..1d580bf 100644
--- a/src/xvd_mixer.c
+++ b/src/xvd_mixer.c
@@ -370,7 +370,10 @@ xvd_calculate_avg_volume(XvdInstance *Inst,
 			
 			s += ((volumes[i] - Inst->track->min_volume) * 100 / step);
 		}
-		Inst->current_vol = s/num_channels;
+		if(num_channels)
+			Inst->current_vol = s/num_channels;
+		else
+			Inst->current_vol = 0;
 	}
 	else {
 		Inst->current_vol = 0.0;



More information about the Xfce4-commits mailing list