Skip to content

Commit 7b65da8

Browse files
committed
vdisp/aggregate codec probe: break if found
no need to iterate further if match found If display misbehaves (outputs one codec multiple times), it causes that codec to be elimited later (if the count != 1 for 2 devices) or more in case of eg. 3 devices and the codec being listed 2-times for one and no for another, it will be falsely accepted.
1 parent b80eb82 commit 7b65da8

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/video_display/aggregate.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* @author Martin Pulec <[email protected]>
44
*/
55
/*
6-
* Copyright (c) 2011-2023 CESNET, z. s. p. o.
6+
* Copyright (c) 2011-2025 CESNET
77
* All rights reserved.
88
*
99
* Redistribution and use in source and binary forms, with or without
@@ -289,6 +289,7 @@ static bool display_aggregate_get_property(void *state, int property, void *val,
289289
for(sub_codec = 0; sub_codec < lens[i] / sizeof(codec_t); ++sub_codec) {
290290
if(examined == codecs[i][sub_codec]) {
291291
++found;
292+
break;
292293
}
293294
}
294295
}

0 commit comments

Comments
 (0)