mirror of
https://gitlab.uni-freiburg.de/opensourcevdi/spice-common
synced 2025-12-26 14:18:36 +00:00
coverity: remove structurally dead code
The loop (for (;;)) will be executed only once, so, no reason for keeping it. Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com> Acked-by: Christophe Fergeau <cfergeau@redhat.com>
This commit is contained in:
parent
83b84428ec
commit
a8f756eabf
@ -323,18 +323,15 @@ match: // RLE or dictionary (both are encoded by distance from ref (-1) a
|
||||
// TODO: maybe separate a run from the same seg or from different ones in order
|
||||
// to spare ref < ref_limit and that way we can also perform 8 calls of
|
||||
// (ref++ != ip++) outside a loop
|
||||
for (;;) {
|
||||
while ((ip < ip_bound) && (ref < ref_limit)) {
|
||||
if (!SAME_PIXEL(*ref, *ip)) {
|
||||
ref++;
|
||||
ip++;
|
||||
break;
|
||||
} else {
|
||||
ref++;
|
||||
ip++;
|
||||
}
|
||||
while ((ip < ip_bound) && (ref < ref_limit)) {
|
||||
if (!SAME_PIXEL(*ref, *ip)) {
|
||||
ref++;
|
||||
ip++;
|
||||
break;
|
||||
} else {
|
||||
ref++;
|
||||
ip++;
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user