aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2014-10-01 11:20:51 -0500
committerTed Gould <ted@gould.cx>2014-10-01 11:20:51 -0500
commit06367d1c8d9f2238f23b29210bb2434917d2c7c2 (patch)
tree23a4249f7102152ec0812c5092872dce22d731c0 /src
parent6f911c1d1ea7caa5031271eb9f2a3d295c492edc (diff)
downloadayatana-indicator-sound-06367d1c8d9f2238f23b29210bb2434917d2c7c2.tar.gz
ayatana-indicator-sound-06367d1c8d9f2238f23b29210bb2434917d2c7c2.tar.bz2
ayatana-indicator-sound-06367d1c8d9f2238f23b29210bb2434917d2c7c2.zip
Can get set at startup before we have a PA connection, shouldn't be a critical in that case, should just fail
Diffstat (limited to 'src')
-rw-r--r--src/volume-control.vala3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/volume-control.vala b/src/volume-control.vala
index 2efa186..afcca15 100644
--- a/src/volume-control.vala
+++ b/src/volume-control.vala
@@ -327,7 +327,8 @@ public class VolumeControl : Object
bool set_volume_internal (double volume)
{
- return_val_if_fail (context.get_state () == Context.State.READY, false);
+ if (context.get_state () != Context.State.READY)
+ return false;
if (_volume != volume) {
_volume = volume;