-Weverything for clang, -Werror
tidy up code
fix memory errors