Add unistd.h header
"similiar" --> "similar"
Fix null pointer dereference, closes #26