Commit 942391f3 authored by Jeremy White's avatar Jeremy White Committed by Frediano Ziglio

Screen for negative inputs for full_screen_fps.

This makes the treatment of the logic condition in display.c
match that of scan.c.
Acked-by: Frediano Ziglio's avatarFrediano Ziglio <fziglio@redhat.com>
parent afc5006e
...@@ -408,7 +408,7 @@ int display_open(display_t *d, session_t *session) ...@@ -408,7 +408,7 @@ int display_open(display_t *d, session_t *session)
return X11SPICE_ERR_NODAMAGE; return X11SPICE_ERR_NODAMAGE;
} }
if (session->options.full_screen_fps == 0) { if (session->options.full_screen_fps <= 0) {
dcookie = dcookie =
xcb_damage_query_version(d->c, XCB_DAMAGE_MAJOR_VERSION, XCB_DAMAGE_MINOR_VERSION); xcb_damage_query_version(d->c, XCB_DAMAGE_MAJOR_VERSION, XCB_DAMAGE_MINOR_VERSION);
damage_version = xcb_damage_query_version_reply(d->c, dcookie, &error); damage_version = xcb_damage_query_version_reply(d->c, dcookie, &error);
...@@ -747,7 +747,7 @@ void display_close(display_t *d) ...@@ -747,7 +747,7 @@ void display_close(display_t *d)
{ {
shm_cache_destroy(d); shm_cache_destroy(d);
g_mutex_clear(&d->shm_cache_mutex); g_mutex_clear(&d->shm_cache_mutex);
if (d->session->options.full_screen_fps == 0) { if (d->session->options.full_screen_fps <= 0) {
xcb_damage_destroy(d->c, d->damage); xcb_damage_destroy(d->c, d->damage);
} }
display_destroy_screen_images(d); display_destroy_screen_images(d);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment