diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/string/memccpy.c | 2 | ||||
-rw-r--r-- | src/string/stpncpy.c | 2 | ||||
-rw-r--r-- | src/string/strlcpy.c | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/src/string/memccpy.c b/src/string/memccpy.c index 4a875cf5..2ccb31bb 100644 --- a/src/string/memccpy.c +++ b/src/string/memccpy.c @@ -22,7 +22,7 @@ void *memccpy(void *dest, const void *src, int c, size_t n) k = ONES * c; wd=(void *)d; ws=(const void *)s; for (; n>=sizeof(size_t) && !HASZERO(*ws^k); - n-=sizeof(size_t), ws++, *wd++) *wd = *ws; + n-=sizeof(size_t), ws++, wd++) *wd = *ws; d=(void *)wd; s=(const void *)ws; } for (; n && (*d=*s)!=c; n--, s++, d++); diff --git a/src/string/stpncpy.c b/src/string/stpncpy.c index 473db17e..a04cdce8 100644 --- a/src/string/stpncpy.c +++ b/src/string/stpncpy.c @@ -19,7 +19,7 @@ char *__stpncpy(char *d, const char *s, size_t n) if (!n || !*s) goto tail; wd=(void *)d; ws=(const void *)s; for (; n>=sizeof(size_t) && !HASZERO(*ws); - n-=sizeof(size_t), ws++, *wd++) *wd = *ws; + n-=sizeof(size_t), ws++, wd++) *wd = *ws; d=(void *)wd; s=(const void *)ws; } for (; n && (*d=*s); n--, s++, d++); diff --git a/src/string/strlcpy.c b/src/string/strlcpy.c index bbebf1db..6aeb106a 100644 --- a/src/string/strlcpy.c +++ b/src/string/strlcpy.c @@ -21,7 +21,7 @@ size_t strlcpy(char *d, const char *s, size_t n) if (n && *s) { wd=(void *)d; ws=(const void *)s; for (; n>=sizeof(size_t) && !HASZERO(*ws); - n-=sizeof(size_t), ws++, *wd++) *wd = *ws; + n-=sizeof(size_t), ws++, wd++) *wd = *ws; d=(void *)wd; s=(const void *)ws; } } |