From 77ffc94677fc98b9c20ca5ef80b2d8f6233cf2a8 Mon Sep 17 00:00:00 2001 From: Michael Davidsaver Date: Fri, 13 Jun 2014 15:37:13 -0400 Subject: [PATCH] out of caution use memmove instead of memcpy --- src/ioc/db/dbConvert.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/ioc/db/dbConvert.c b/src/ioc/db/dbConvert.c index 7223e97f2..00a87c896 100644 --- a/src/ioc/db/dbConvert.c +++ b/src/ioc/db/dbConvert.c @@ -51,11 +51,11 @@ static void copyNoConvert(const void *pfrom, if(offset>0 && offset < no_bytes && offset+nRequest > no_bytes) { const size_t N = no_bytes - offset; /* copy with wrap */ - memcpy(pto, pfrom + offset, N); - memcpy(pto + N, pfrom, nRequest - N); + memmove(pto, pfrom + offset, N); + memmove(pto + N, pfrom, nRequest - N); } else { /* no wrap, just copy */ - memcpy(pto, pfrom + offset, nRequest); + memmove(pto, pfrom + offset, nRequest); } } #define COPYNOCONVERT(N, FROM, TO, NREQ, NO_ELEM, OFFSET) \