From 10a8db4bedc18df8f8ef14733c6e35b38ca4ef12 Mon Sep 17 00:00:00 2001 From: hunt Date: Tue, 11 Apr 2006 05:13:46 +0000 Subject: 2006-04-10 Martin Hunt * string.c (_stp_string_cat_cstr): No need to copy terminating 0. --- runtime/string.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'runtime/string.c') diff --git a/runtime/string.c b/runtime/string.c index efb4d595..fa8e2dda 100644 --- a/runtime/string.c +++ b/runtime/string.c @@ -134,7 +134,7 @@ void _stp_string_cat_cstr (String str1, const char *str2) num = STP_PRINT_BUF_LEN; } buf = &_stp_pbuf[cpu][STP_PRINT_BUF_START] + _stp_pbuf_len[cpu]; - memcpy (buf, str2, num + 1); + memcpy (buf, str2, num); _stp_pbuf_len[cpu] += num; } else { int size = STP_STRING_SIZE - str1->len - 1; -- cgit