diff options
author | Denys Vlasenko | 2017-07-21 18:51:29 +0200 |
---|---|---|
committer | Denys Vlasenko | 2017-07-21 18:51:29 +0200 |
commit | da2244fe48b7f1223427a4c1e91d86e398bbceb4 (patch) | |
tree | ace4f9150179e9f56c3965751947dcedd1da974d | |
parent | fd5e66eb8eb4e39460a6cfde4b10dcab3870f26b (diff) | |
download | busybox-da2244fe48b7f1223427a4c1e91d86e398bbceb4.zip busybox-da2244fe48b7f1223427a4c1e91d86e398bbceb4.tar.gz |
ash: use mempcpy() where appropriate
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-rw-r--r-- | shell/ash.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/shell/ash.c b/shell/ash.c index a461bb7..c8b2adf 100644 --- a/shell/ash.c +++ b/shell/ash.c @@ -2315,10 +2315,10 @@ setvar(const char *name, const char *val, int flags) INT_OFF; nameeq = ckmalloc(namelen + vallen + 2); - p = memcpy(nameeq, name, namelen) + namelen; + p = mempcpy(nameeq, name, namelen); if (val) { *p++ = '='; - p = memcpy(p, val, vallen) + vallen; + p = mempcpy(p, val, vallen); } *p = '\0'; setvareq(nameeq, flags | VNOSAVE); |