String account = (String)session.getAttribute("account");
if(account == null || account =="")
{
  session.removeAttribute("account");
  response.sendRedirect("../index.jsp");
}
只看了只这几行,就有个疑问,如果说account==null了,那么再调用session.remove...("account")这样没有意义。