Skip to content

Commit

Permalink
Merge tag 'm68knommu-for-v6.2' of git://git.kernel.org/pub/scm/linux/…
Browse files Browse the repository at this point in the history
…kernel/git/gerg/m68knommu

Pull m68knommu update from Greg Ungerer:
 "Only a single change to use the safer strscpy() instead of strncpy()
  when setting up the cmdline"

* tag 'm68knommu-for-v6.2' of git://git.kernel.org/pub/scm/linux/kernel/git/gerg/m68knommu:
  m68k: use strscpy() to instead of strncpy()
  • Loading branch information
torvalds committed Dec 20, 2022
2 parents 32d528c + af5d74e commit b6bb967
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions arch/m68k/kernel/setup_no.c
Original file line number Diff line number Diff line change
Expand Up @@ -90,8 +90,7 @@ void __init setup_arch(char **cmdline_p)
config_BSP(&command_line[0], sizeof(command_line));

#if defined(CONFIG_BOOTPARAM)
strncpy(&command_line[0], CONFIG_BOOTPARAM_STRING, sizeof(command_line));
command_line[sizeof(command_line) - 1] = 0;
strscpy(&command_line[0], CONFIG_BOOTPARAM_STRING, sizeof(command_line));
#endif /* CONFIG_BOOTPARAM */

process_uboot_commandline(&command_line[0], sizeof(command_line));
Expand Down

0 comments on commit b6bb967

Please sign in to comment.