Repository navigation
Use memmove instead of copy_mem_* and user_bcopy - #183
Conversation
Replace the element-wise copy helpers in [sdcz]memory.c by memmove. The source and destination can overlap when the user-supplied work array is reorganized, which memmove handles, and the byte count is passed as size_t instead of int.
27cd19d to
b61863c
Compare
|
I just fixed a bug in this commit: 53b23ed Can you re-submit your PR based on my new commit? Thanks! |
|
Thanks for the hint. I already rebased the commit. What do you think, should we remove the helper functions now? |
|
I merged this. But, what do you mean by helper functions? |
|
The functions that got replaced and are no longer used like |
|
We can keep them for some while. We will see the users experiences. The concern is memmove may not yet be supported by all compilers. Since there are quite a few bug fixes lately, I'll put up a release later today. |
|
|
Replace the element-wise copy helpers in [sdcz]memory.c by memmove. The source and destination can overlap when the user-supplied work array is reorganized, which memmove handles, and the byte count is passed as size_t instead of int.
The helper functions themselves are kept for now. I can provide a patch removing them.