diff src/getchar.c @ 1455:ca501ab2fdb3 v7.1.170

updated for version 7.1-170
author vimboss
date Fri, 07 Dec 2007 16:30:42 +0000
parents bdcfe793d49f
children ceaf71b15d81
line wrap: on
line diff
--- a/src/getchar.c
+++ b/src/getchar.c
@@ -253,8 +253,9 @@ add_buff(buf, s, slen)
 	return;
     }
     else if (buf->bh_index != 0)
-	STRCPY(buf->bh_first.b_next->b_str,
-				 buf->bh_first.b_next->b_str + buf->bh_index);
+	mch_memmove(buf->bh_first.b_next->b_str,
+		    buf->bh_first.b_next->b_str + buf->bh_index,
+		    STRLEN(buf->bh_first.b_next->b_str + buf->bh_index) + 1);
     buf->bh_index = 0;
 
     if (buf->bh_space >= (int)slen)