check for false in readdir