From 173a9cbe7031bc3574b3f41cb2d2375cf959ff2a Mon Sep 17 00:00:00 2001 From: Edgar Toernig Date: Mon, 30 Oct 2006 17:39:17 -0800 Subject: [PATCH] Use memmove instead of memcpy for overlapping areas Signed-off-by: Junio C Hamano --- imap-send.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/imap-send.c b/imap-send.c index 16804ab28..a6a65680e 100644 --- a/imap-send.c +++ b/imap-send.c @@ -272,7 +272,7 @@ buffer_gets( buffer_t * b, char **s ) n = b->bytes - start; if (n) - memcpy( b->buf, b->buf + start, n ); + memmove(b->buf, b->buf + start, n); b->offset -= start; b->bytes = n; start = 0; -- 2.30.2