Code assumes that tableIndex is never 0, while GCC cannot infer it. So include tableIndex=0 case into already handled error cases.
GCC/Mingw complains with: /home/eric/work/wine/dlls/inetmib1/main.c: In function 'mib2IfEntryQuery': /home/eric/work/wine/dlls/inetmib1/main.c:646:25: warning: array subscript 4294967295 is above array bounds of 'MIB_IFROW[1]' {aka 'struct _MIB_IFROW[1]'} [-Warray-bounds] 646 | &ifTable->table[tableIndex - 1], item, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ In file included from /home/eric/work/wine/include/ipmib.h:21, from /home/eric/work/wine/include/iprtrmib.h:24, from /home/eric/work/wine/include/iphlpapi.h:25, from /home/eric/work/wine/dlls/inetmib1/main.c:30: /home/eric/work/wine/include/ifmib.h:66:15: note: while referencing 'table' 66 | MIB_IFROW table[1];
Signed-off-by: Eric Pouech eric.pouech@gmail.com