Files
linux/drivers
Arnd Bergmann 11de2fae34 net: qed: use correct strncpy() size
commit 11f711081a upstream.

passing the strlen() of the source string as the destination
length is pointless, and gcc-8 now warns about it:

drivers/net/ethernet/qlogic/qed/qed_debug.c: In function 'qed_grc_dump':
include/linux/string.h:253: error: 'strncpy' specified bound depends on the length of the source argument [-Werror=stringop-overflow=]

This changes qed_grc_dump_big_ram() to instead uses the length of
the destination buffer, and use strscpy() to guarantee nul-termination.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-08 13:05:09 +01:00
..
2018-07-22 14:27:36 +02:00
2018-02-25 11:05:55 +01:00
2018-08-22 07:47:14 +02:00
2017-09-09 17:39:41 +02:00
2018-12-08 13:05:09 +01:00
2018-11-10 07:43:00 -08:00
2018-11-13 11:17:04 -08:00
2018-11-13 11:17:02 -08:00
2018-12-08 13:05:07 +01:00
2018-11-27 16:09:41 +01:00
2018-10-03 17:01:42 -07:00
2018-11-23 08:20:37 +01:00