Fix leaks, and replace continue statements with if/else.
Fix leaks, and replace continue statements with if/else.

Compare UTI instead of using isEqualToString: with path extension.
WoLpH/skim,ycaihua/skim-app,WoLpH/skim,ycaihua/skim-app,WoLpH/skim,WoLpH/skim,ycaihua/skim-app,ycaihua/skim-app,ycaihua/skim-app,WoLpH/skim