URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=e48ab21267c90bf5f870003299e00ea1656e2d7e Submitter: "Martin Mathieson <martin.r.mathie...@googlemail.com>" Changed: branch: master Repository: wireshark
Commits: e48ab21 by Martin Mathieson (martin.mathie...@keysight.com): BER: Fix order of loop tests to avoid overrunning array. Reported by cppcheck: epan/dissectors/packet-ber.c:2603:35: warning: Array index 'set_idx' is used before limits check. [arrayIndexThenCheck] for (set_idx = 0; (cset = &set[set_idx])->func && (set_idx < MAX_SET_ELEMENTS); set_idx++) { ^ epan/dissectors/packet-ber.c:2759:40: warning: Array index 'set_idx' is used before limits check. [arrayIndexThenCheck] for (set_idx = 0; (cset = &set[set_idx])->func && (set_idx < MAX_SET_ELEMENTS); set_idx++) { ^ Change-Id: Ifbb9f1d2e9062a5c55190ea68df2226f3af8f21a Reviewed-on: https://code.wireshark.org/review/38166 Petri-Dish: Martin Mathieson <martin.r.mathie...@googlemail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Pascal Quantin <pas...@wireshark.org> Reviewed-by: Martin Mathieson <martin.r.mathie...@googlemail.com> Actions performed: from 521180d [Automatic update for 2020-08-16] add e48ab21 BER: Fix order of loop tests to avoid overrunning array. Summary of changes: epan/dissectors/packet-ber.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) ___________________________________________________________________________ Sent via: Wireshark-commits mailing list <wireshark-commits@wireshark.org> Archives: https://www.wireshark.org/lists/wireshark-commits Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-commits mailto:wireshark-commits-requ...@wireshark.org?subject=unsubscribe