summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJonathon Jongsma <jjongsma@redhat.com>2015-02-06 14:41:22 -0600
committerFabiano FidĂȘncio <fidencio@redhat.com>2015-02-23 23:00:46 +0100
commitb88894322e0c354b5298f5cb946e73b9b46f35c4 (patch)
treeb3f5b6730463a7c250d9eabac4e734fba28e828e
parente49e6e5b8937daf553a615c12925296ef3b68dcb (diff)
downloadspice-b88894322e0c354b5298f5cb946e73b9b46f35c4.tar.gz
spice-b88894322e0c354b5298f5cb946e73b9b46f35c4.tar.xz
spice-b88894322e0c354b5298f5cb946e73b9b46f35c4.zip
Remove global 'reds' usage from stream.c
Use the server variable from the display channel rather than the global variable.
-rw-r--r--server/stream.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/server/stream.c b/server/stream.c
index e1627762..f33fdda9 100644
--- a/server/stream.c
+++ b/server/stream.c
@@ -148,8 +148,9 @@ static int is_stream_start(Drawable *drawable)
(RED_STREAM_GRADUAL_FRAMES_START_CONDITION * drawable->frames_count)));
}
-static void update_copy_graduality(Drawable *drawable)
+static void update_copy_graduality(DisplayChannel *display, Drawable *drawable)
{
+ RedsState *reds = red_channel_get_server((RedChannel*)display);
SpiceBitmap *bitmap;
spice_return_if_fail(drawable->red_drawable->type == QXL_DRAW_COPY);
@@ -452,7 +453,7 @@ static int stream_add_frame(DisplayChannel *display,
int gradual_frames_count,
int last_gradual_frame)
{
- update_copy_graduality(frame_drawable);
+ update_copy_graduality(display, frame_drawable);
frame_drawable->frames_count = frames_count + 1;
frame_drawable->gradual_frames_count = gradual_frames_count;