diff options
author | Denys Vlasenko <vda.linux@googlemail.com> | 2018-12-06 12:01:17 +0100 |
---|---|---|
committer | Denys Vlasenko <vda.linux@googlemail.com> | 2018-12-06 12:01:17 +0100 |
commit | 4c30406df6d44447a3ae147f3b85c6726bc0f739 (patch) | |
tree | bd184748552d869254e19b2dc93681e84a87398d /miscutils/bc.c | |
parent | 23c2e9fcf9a61da814aee986b30efd9c531fb94d (diff) | |
download | busybox-w32-4c30406df6d44447a3ae147f3b85c6726bc0f739.tar.gz busybox-w32-4c30406df6d44447a3ae147f3b85c6726bc0f739.tar.bz2 busybox-w32-4c30406df6d44447a3ae147f3b85c6726bc0f739.zip |
bc: do not needlessly use strcat
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'miscutils/bc.c')
-rw-r--r-- | miscutils/bc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/miscutils/bc.c b/miscutils/bc.c index ad6831683..06b148481 100644 --- a/miscutils/bc.c +++ b/miscutils/bc.c | |||
@@ -1148,7 +1148,7 @@ static void bc_vec_concat(BcVec *v, const char *str) | |||
1148 | len = v->len + strlen(str); | 1148 | len = v->len + strlen(str); |
1149 | 1149 | ||
1150 | if (v->cap < len) bc_vec_grow(v, len - v->len); | 1150 | if (v->cap < len) bc_vec_grow(v, len - v->len); |
1151 | strcat(v->v, str); | 1151 | strcpy(v->v + v->len, str); |
1152 | 1152 | ||
1153 | v->len = len; | 1153 | v->len = len; |
1154 | } | 1154 | } |