]> source.dussan.org Git - rspamd.git/commitdiff
[Minor] Use memmove for overlapping memory
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Fri, 7 Apr 2017 12:03:55 +0000 (13:03 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Fri, 7 Apr 2017 12:03:55 +0000 (13:03 +0100)
src/libutil/http.c

index b46009794cf43c8616b2854a25b198d631fe671c..24c5e730c09cbec9864c5686352055be1cd394bd 100644 (file)
@@ -3713,7 +3713,7 @@ rspamd_http_normalize_path_inplace (gchar *path, gsize len, gsize *nlen)
                                else {
                                        /* We have something like bla../, so we need to copy it as is */
                                        if (o > path && dot && p > dot) {
-                                               memcpy (o, dot, p - dot);
+                                               memmove (o, dot, p - dot);
                                                o += p - dot;
                                        }