ALSA: hrtimer: Replace deprecated strcpy() with strscpy()
PATCH 1/1 ALSA: hrtimer: Replace deprecated strcpy() with strscpy()
strcpy() is deprecated; use strscpy() instead.
No functional changes intended.
Signed-off-by Thorsten Blum <[email protected]>
--- sound/core/hrtimer.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
sound/core/hrtimer.c +2 -1
@@ -6,6 +6,7 @@#include <linux/init.h> #include <linux/slab.h> +#include <linux/string.h> #include <linux/module.h> #include <linux/moduleparam.h> #include <linux/hrtimer.h>
@@ -138,7 +139,7 @@ static int __init snd_hrtimer_init(void)return err; timer->module =THIS_MODULE ; -strcpy (timer->name,"HR timer" ); +strscpy (timer->name,"HR timer" ); timer->hw = hrtimer_hw; timer->hw.resolution = resolution; timer->hw.ticks =NANO_SEC / resolution;
Signature · 1 line
2.49.0
Quoted 7 lines · Thorsten Blum
strcpy()is deprecated; usestrscpy()instead.No functional changes intended.
Signed-off-by Thorsten Blum <[email protected]>
Applied now. Thanks.
Takashi