InputDevice: replace strncpy and snprintf in dump
The explicit addition of a null terminator afterwards _should_ have made
the strncpy usage safe, but even so it's harder to understand and adds
an additional copy.
Test: comment out most of the AXES_SEQUENCES list in
libs/input/InputEventLabels.cpp and check that both labels and
numbers are shown correctly in `adb shell dumpsys input`
Bug: 245989146
Flag: EXEMPT refactor
Change-Id: I5a00ec35f8a035b0a29e4f08d8d1c89743ad00d1
Loading
Please register or sign in to comment