Fix including header files

- Use cstdio, cstdlib instead of stdio.h, stdlib.h.
- Include cstring instead of memory.h. memory.h is not standard header file

Please see this patch