Updated to avoid seg fault

Changed a malloc to calloc to avoid a strange seg fault.
Revert last commit and add term char to strings

Forgot to add termination char to the end of my random strings, causing
the weird fault when not initialising memory