fixes #32

added faceguydb's crash fix without the newline changes