[Spice-devel] [PATCH 08/16] Change reds_disable_mm_time() to take RedsState arg

Frediano Ziglio fziglio at redhat.com
Wed Jan 20 07:43:34 PST 2016


From: Jonathon Jongsma <jjongsma at redhat.com>

---
 server/reds.c  | 2 +-
 server/reds.h  | 2 +-
 server/sound.c | 4 ++--
 3 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/server/reds.c b/server/reds.c
index 6232f1d..38e4aef 100644
--- a/server/reds.c
+++ b/server/reds.c
@@ -2969,7 +2969,7 @@ void reds_enable_mm_time(RedsState *reds)
     reds_send_mm_time(reds);
 }
 
-void reds_disable_mm_time(void)
+void reds_disable_mm_time(RedsState *reds)
 {
     reds->mm_time_enabled = FALSE;
 }
diff --git a/server/reds.h b/server/reds.h
index 6afd5b7..294f68c 100644
--- a/server/reds.h
+++ b/server/reds.h
@@ -50,7 +50,7 @@ struct SpiceMigrateState {
 /* main thread only */
 void reds_handle_channel_event(int event, SpiceChannelEventInfo *info);
 
-void reds_disable_mm_time(void);
+void reds_disable_mm_time(RedsState *reds);
 void reds_enable_mm_time(RedsState *reds);
 uint32_t reds_get_mm_time(void);
 void reds_set_client_mouse_allowed(RedsState *reds,
diff --git a/server/sound.c b/server/sound.c
index 09d732d..0890a87 100644
--- a/server/sound.c
+++ b/server/sound.c
@@ -1041,7 +1041,7 @@ SPICE_GNUC_VISIBLE void spice_server_playback_start(SpicePlaybackInstance *sin)
     if (!channel)
         return;
     spice_assert(!playback_channel->base.active);
-    reds_disable_mm_time();
+    reds_disable_mm_time(reds);
     playback_channel->base.active = TRUE;
     if (!playback_channel->base.client_active) {
         snd_set_command(&playback_channel->base, SND_PLAYBACK_CTRL_MASK);
@@ -1174,7 +1174,7 @@ static void on_new_playback_channel(SndWorker *worker)
         snd_set_command((SndChannel *)playback_channel, SND_PLAYBACK_VOLUME_MASK);
     }
     if (playback_channel->base.active) {
-        reds_disable_mm_time();
+        reds_disable_mm_time(reds);
     }
 }
 
-- 
2.4.3



More information about the Spice-devel mailing list