Commit 5eb4b9a
params: Replace deprecated strcpy() with strscpy() and memcpy()
strcpy() is deprecated; use strscpy() and memcpy() instead.
In param_set_copystring(), we can safely use memcpy() because we already
know the length of the source string 'val' and that it is guaranteed to
be NUL-terminated within the first 'kps->maxlen' bytes.
Link: KSPP#88
Signed-off-by: Thorsten Blum <[email protected]>
Reviewed-by: Daniel Gomez <[email protected]>
Reviewed-by: Petr Pavlu <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Daniel Gomez <[email protected]>1 parent 8f5ae30 commit 5eb4b9a
1 file changed
+4
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
513 | 513 | | |
514 | 514 | | |
515 | 515 | | |
| 516 | + | |
516 | 517 | | |
517 | | - | |
| 518 | + | |
518 | 519 | | |
519 | 520 | | |
520 | 521 | | |
521 | 522 | | |
522 | | - | |
| 523 | + | |
523 | 524 | | |
524 | 525 | | |
525 | 526 | | |
| |||
841 | 842 | | |
842 | 843 | | |
843 | 844 | | |
844 | | - | |
| 845 | + | |
845 | 846 | | |
846 | 847 | | |
847 | 848 | | |
| |||
0 commit comments