Fixed a few issues with memory and messed up pointers
Updated readme