diff options
| author | Jaroslav Kysela <[email protected]> | 2023-01-09 15:12:49 +0000 |
|---|---|---|
| committer | Takashi Iwai <[email protected]> | 2023-01-09 16:03:24 +0000 |
| commit | 70051cffb31b5ee09096351c3b41fcae6f89de31 (patch) | |
| tree | c1549eb36aaabf8b820b8097aecee0f3e9d3b82e /tools/perf/scripts/python/flamegraph.py | |
| parent | ALSA: usb-audio: Always initialize fixed_rate in snd_usb_find_implicit_fb_syn... (diff) | |
| download | kernel-70051cffb31b5ee09096351c3b41fcae6f89de31.tar.gz kernel-70051cffb31b5ee09096351c3b41fcae6f89de31.zip | |
ALSA: control-led: use strscpy in set_led_id()
The use of strncpy() in the set_led_id() was incorrect.
The len variable should use 'min(sizeof(buf2) - 1, count)'
expression.
Use strscpy() function to simplify things and handle the error gracefully.
Fixes: a135dfb5de15 ("ALSA: led control - add sysfs kcontrol LED marking layer")
Reported-by: [email protected]
Link: https://lore.kernel.org/alsa-devel/[email protected]/
Cc: <[email protected]>
Signed-off-by: Jaroslav Kysela <[email protected]>
Signed-off-by: Takashi Iwai <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/flamegraph.py')
0 files changed, 0 insertions, 0 deletions
