tccgen.c: Use memmove for struct assignment: dest and src may be equal.

This commit is contained in:
Edmund Grimley Evans 2015-11-04 20:23:17 +00:00
parent 8eab556ac5
commit b051549f2e

View File

@ -2576,7 +2576,8 @@ ST_FUNC void vstore(void)
vpush_global_sym(&func_old_type, TOK_memcpy4); vpush_global_sym(&func_old_type, TOK_memcpy4);
else else
#endif #endif
vpush_global_sym(&func_old_type, TOK_memcpy); /* Use memmove, rather than memcpy, as dest and src may be same: */
vpush_global_sym(&func_old_type, TOK_memmove);
vswap(); vswap();
/* source */ /* source */