Re: [PATCH] net/rds: zero last byte for strncpy
From: Chen Gang <hidden>
Date: 2013-03-08 06:13:47
From: Chen Gang <hidden>
Date: 2013-03-08 06:13:47
于 2013年03月08日 13:36, David Miller 写道:
From: Chen Gang <redacted> Date: Fri, 08 Mar 2013 11:19:32 +0800quoted
for NUL terminated string, need be always sure '\0' in the end. additional info: strncpy will pads with zeroes to the end of the given buffer. should initialise every bit of memory that is going to be copied to userland Signed-off-by: Chen Gang <redacted> Signed-off-by: Ben Hutchings <redacted>Applied.
thanks. -- Chen Gang Asianux Corporation