fix possible bugs find by FindBugs