lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  PHC 
Open Source and information security mailing list archives
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Mon, 11 Aug 2014 21:45:57 +0200
From:	Rickard Strandqvist <>
To:	Wolfram Sang <>
Cc:	Mark D Rustad <>,
	Andrew Morton <>,
	Greg Kroah-Hartman <>,
	Linus Walleij <>,
	Peter Hurley <>,
	"" <>
Subject: Re: [PATCH] misc: ti-st: st_kim.c: Cleaning up missing null-terminate
 after strncpy call

2014-08-11 11:14 GMT+02:00 Wolfram Sang <>:
>> >     strncpy(kim_data->dev_name, buf, count);
>> > +   kim_data->dev_name[count - 1] = '\n';
>> Of course this does not add termination, but adds a newline at the end of the buffer? Huh?
> strlcpy?

Hi Wolfram

Sure, strlcpy is preferable in many ways if we only can guarantee that
it is safe.
I have seldom been so much criticism when I start switching to
strlcpy, although much of it was justified :)
Even Linus was getting into the debate.  See more:

I do this only when I'm sure it will not cause any other problems.
But if you or anyone else can guarantee that in this case, so I'd make
a new patch.

Kind regards
Rickard Strandqvist
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

Powered by blists - more mailing lists