[SLOF] [PATCH] net: use FILENAME_MAX for arrays storing file name
Segher Boessenkool
segher at kernel.crashing.org
Wed Aug 2 03:08:37 AEST 2017
On Tue, Aug 01, 2017 at 02:38:57PM +0530, Nikunj A Dadhania wrote:
> Magic numbers were used at multiple places in the network code for size for
> maximum file name. Use FILENAME_MAX uniformly.
>
> Static analysis tool was reporting issues with using strcpy and suggesting to
> be replaced with strncpy.
You're not zero-terminating any of these strings, nor handling overflow
in any way.
Segher
More information about the SLOF
mailing list