Fix bug of handling file names ended with spaces.

Thoes files/folders should be ignore when checking worktree
cleaness.