mirror of
https://gitlab.uni-freiburg.de/opensourcevdi/spice
synced 2026-08-16 18:17:46 +00:00
Remove X == TRUE tests for non-boolean values
Using X == TRUE is fragile, since the input value is a uint8_t. It would be surprising if the value was set to 2 or 0xFF and the test failed. Signed-off-by: Christophe de Dinechin <dinechin@redhat.com> Acked-by: Frediano Ziglio <fziglio@redhat.com>
This commit is contained in:
parent
5277ac8921
commit
be727eb822
@ -398,7 +398,7 @@ static void add_drawable_surface_images(DisplayChannelClient *dcc, Drawable *dra
|
||||
|
||||
surface_id = drawable->surface_deps[x];
|
||||
if (surface_id != -1) {
|
||||
if (dcc->priv->surface_client_created[surface_id] == TRUE) {
|
||||
if (dcc->priv->surface_client_created[surface_id]) {
|
||||
continue;
|
||||
}
|
||||
dcc_create_surface(dcc, surface_id);
|
||||
@ -407,7 +407,7 @@ static void add_drawable_surface_images(DisplayChannelClient *dcc, Drawable *dra
|
||||
}
|
||||
}
|
||||
|
||||
if (dcc->priv->surface_client_created[drawable->surface_id] == TRUE) {
|
||||
if (dcc->priv->surface_client_created[drawable->surface_id]) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user