mirror of
https://gitlab.uni-freiburg.de/opensourcevdi/spice
synced 2026-08-06 20:27:43 +00:00
clang-tidy: test for empty instead of size
Found with readability-container-size-empty This has the potential for extra performance as it's not checking for every single element. Signed-off-by: Rosen Penev <rosenp@gmail.com> Acked-by: Frediano Ziglio <freddy77@gmail.com>
This commit is contained in:
parent
23bd93bfb4
commit
04e885b291
@ -317,7 +317,7 @@ red_char_device_send_to_client_tokens_absorb(RedCharDevice *dev,
|
||||
}
|
||||
dev_client->num_send_tokens += tokens;
|
||||
|
||||
if (dev_client->send_queue.size()) {
|
||||
if (!dev_client->send_queue.empty()) {
|
||||
spice_assert(dev_client->num_send_tokens == tokens);
|
||||
red_char_device_client_send_queue_push(dev_client);
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user