From 3cc54e91bf24d17d92d386fc06b938938e84732f Mon Sep 17 00:00:00 2001 From: "gary.li.wenchao.4" Date: Wed, 17 Mar 2010 10:35:43 +0000 Subject: [PATCH] fixed strlcpy() git-svn-id: https://rt-thread.googlecode.com/svn/trunk@502 bbd45198-f89e-11dd-88c7-29a3b14d5316 --- libc/minilibc/string.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libc/minilibc/string.c b/libc/minilibc/string.c index 2de4f20790..e7fc6d4009 100644 --- a/libc/minilibc/string.c +++ b/libc/minilibc/string.c @@ -38,7 +38,7 @@ size_t strlcpy(char *dst, const char *src, size_t siz) register size_t n = siz; /* Copy as many bytes as will fit */ - if (n != 0 && --n != 0) + if (n != 0) { do { -- GitLab