Fix possible resource leak flagged by eclipse.
Remove unused imports.