diff options
author | Andrew Vasquez <andrew.vasquez@cavium.com> | 2018-02-07 08:12:35 -0800 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2018-02-13 21:35:39 -0500 |
commit | 1683ce57f568c7c92d53e9234624a53554a29cd5 (patch) | |
tree | 1010454f842fd744423801b10697d4b867f7e88d /include/linux/compiler-gcc.h | |
parent | f3767225021a48fc419d963559793e585da88b3d (diff) |
scsi: qedi: Fix truncation of CHAP name and secret
The data in NVRAM is not guaranteed to be NUL terminated. Since
snprintf expects byte-stream to accommodate null byte, the CHAP secret
is truncated. Use sprintf instead of snprintf to fix the truncation of
CHAP name and secret.
Signed-off-by: Andrew Vasquez <andrew.vasquez@cavium.com>
Signed-off-by: Nilesh Javali <nilesh.javali@cavium.com>
Reviewed-by: Bart Van Assche <bart.vanassche@wdc.com>
Acked-by: Chris Leech <cleech@redhat.com>
Acked-by: Lee Duncan <lduncan@suse.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'include/linux/compiler-gcc.h')
0 files changed, 0 insertions, 0 deletions