[pypy-commit] cffi default: Use memcpy here

arigo pypy.commits at gmail.com
Thu Aug 30 06:26:31 EDT 2018


Author: Armin Rigo <arigo at tunes.org>
Branch: 
Changeset: r3153:1443130c25e1
Date: 2018-08-30 11:53 +0200
http://bitbucket.org/cffi/cffi/changeset/1443130c25e1/

Log:	Use memcpy here

diff --git a/c/_cffi_backend.c b/c/_cffi_backend.c
--- a/c/_cffi_backend.c
+++ b/c/_cffi_backend.c
@@ -1475,7 +1475,7 @@
         if (cd->c_type == ct)
         {
             Py_ssize_t n = get_array_length(cd);
-            memmove(data, cd->c_data, n * ctitem->ct_size);
+            memcpy(data, cd->c_data, n * ctitem->ct_size);
             return 0;
         }
     }


More information about the pypy-commit mailing list