[rds-devel] [PATCH] net/rds: zero last byte for strncpy
David Miller
davem at davemloft.net
Thu Mar 7 21:36:30 PST 2013
From: Chen Gang <gang.chen at asianux.com>
Date: Fri, 08 Mar 2013 11:19:32 +0800
>
> 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 <gang.chen at asianux.com>
> Signed-off-by: Ben Hutchings <bhutchings at solarflare.com>
Applied.
More information about the rds-devel
mailing list