aboutsummaryrefslogtreecommitdiff
path: root/ui/spice-display.c
diff options
context:
space:
mode:
authorGonglei <arei.gonglei@huawei.com>2016-05-12 17:57:08 +0800
committerGerd Hoffmann <kraxel@redhat.com>2016-05-12 16:41:46 +0200
commit28f4a7083dcca084243e313ab18fcdb20d60334e (patch)
treef375fb54438da5bbc51c7e9337738ac40ecccd8a /ui/spice-display.c
parentf454f49c42d4ec7bdbbb5a7d9c0c8bfb24b28ca4 (diff)
spice: fix coverity complains
Remove the unnecessary NULL check. Signed-off-by: Gonglei <arei.gonglei@huawei.com> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Message-id: 1463047028-123868-3-git-send-email-arei.gonglei@huawei.com Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'ui/spice-display.c')
-rw-r--r--ui/spice-display.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/ui/spice-display.c b/ui/spice-display.c
index 2a77a545ae..0553c5e5b0 100644
--- a/ui/spice-display.c
+++ b/ui/spice-display.c
@@ -774,9 +774,7 @@ static void display_mouse_define(DisplayChangeListener *dcl,
SimpleSpiceDisplay *ssd = container_of(dcl, SimpleSpiceDisplay, dcl);
qemu_mutex_lock(&ssd->lock);
- if (c) {
- cursor_get(c);
- }
+ cursor_get(c);
cursor_put(ssd->cursor);
ssd->cursor = c;
ssd->hot_x = c->hot_x;