diff options
author | Philippe Mathieu-Daudé <philmd@linaro.org> | 2024-05-23 16:06:20 +0100 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2024-05-28 14:20:48 +0100 |
commit | 84ce4b9b9943d26c9d9c7ea8abd924033c125535 (patch) | |
tree | d7b526057af11dd743f84387c8f1cdc17c446f6c /util/qemu-co-timeout.c | |
parent | daafa78b297291fea36fb4daeed526705fa7c035 (diff) | |
download | qemu-84ce4b9b9943d26c9d9c7ea8abd924033c125535.zip qemu-84ce4b9b9943d26c9d9c7ea8abd924033c125535.tar.gz qemu-84ce4b9b9943d26c9d9c7ea8abd924033c125535.tar.bz2 |
hw/input/tsc2005: Fix -Wchar-subscripts warning in tsc2005_txrx()
Check the function index is in range and use an unsigned
variable to avoid the following warning with GCC 13.2.0:
[666/5358] Compiling C object libcommon.fa.p/hw_input_tsc2005.c.o
hw/input/tsc2005.c: In function 'tsc2005_timer_tick':
hw/input/tsc2005.c:416:26: warning: array subscript has type 'char' [-Wchar-subscripts]
416 | s->dav |= mode_regs[s->function];
| ~^~~~~~~~~~
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-id: 20240508143513.44996-1-philmd@linaro.org
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
[PMM: fixed missing ')']
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'util/qemu-co-timeout.c')
0 files changed, 0 insertions, 0 deletions