<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">
From: walter harms &lt;wharms@bfs.de&gt;

this clarifies the documentation on the behavier of strncpy().

Signed-off-by: Domen Puncer &lt;domen@coderock.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@osdl.org&gt;
---

 25-akpm/lib/string.c |    4 ++++
 1 files changed, 4 insertions(+)

diff -puN lib/string.c~lib-c-documentation-strncpy lib/string.c
--- 25/lib/string.c~lib-c-documentation-strncpy	Fri Apr  8 16:30:18 2005
+++ 25-akpm/lib/string.c	Fri Apr  8 16:30:18 2005
@@ -85,6 +85,10 @@ EXPORT_SYMBOL(strcpy);
  *
  * The result is not %NUL-terminated if the source exceeds
  * @count bytes.
+ *
+ * In the case where the length of @src is less than  that  of
+ * count, the remainder of @dest will be padded with %NUL.
+ *
  */
 char * strncpy(char * dest,const char *src,size_t count)
 {
_
</pre></body></html>