Commit e8fb5ec
ecryptfs: Replace memcpy + NUL termination in ecryptfs_new_file_context
Use strscpy() to copy the NUL-terminated '->global_default_cipher_name'
to the destination buffer instead of using memcpy() followed by a manual
NUL termination. Remove the now-unused local variable 'cipher_name_len'.
Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev>
Signed-off-by: Tyler Hicks <code@tyhicks.com>1 parent 0529a80 commit e8fb5ec
1 file changed
Lines changed: 2 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
679 | 679 | | |
680 | 680 | | |
681 | 681 | | |
682 | | - | |
683 | 682 | | |
684 | 683 | | |
685 | 684 | | |
| |||
693 | 692 | | |
694 | 693 | | |
695 | 694 | | |
696 | | - | |
697 | | - | |
698 | | - | |
699 | | - | |
700 | | - | |
701 | | - | |
| 695 | + | |
| 696 | + | |
702 | 697 | | |
703 | 698 | | |
704 | 699 | | |
| |||
0 commit comments