I have implemented based on Harry's suggestion to use memmove lib(to be in safe side). until right now I did some simple unit test and didn't find any problem. But I also struggle to prove it actually solve the problem. stay tuned for my update
Thanks
Rui