Program: 57691
Project: 57691
Buggy source:
/** 
 * 加载试题的详细信息.
 * @param problemID - 试题的唯一标识符
 * @param request - HttpRequest对象
 * @param response - HttpResponse对象
 * @return 包含试题详细信息的ModelAndView对象
 */
@RequestMapping(value="String_Node_Str",method=RequestMethod.GET) public ModelAndView problemView(@PathVariable("String_Node_Str") long problemId,HttpServletRequest request,HttpServletResponse response){
  HttpSession session=request.getSession();
  boolean isLoggedIn=isLoggedIn(session);
  Problem problem=problemService.getProblem(problemId);
  if (problem == null) {
    throw new ResourceNotFoundException();
  }
 else   if (!problem.isPublic()) {
    boolean isAllowToAccess=false;
    if (isLoggedIn) {
      User currentUser=HttpSessionParser.getCurrentUser(session);
      if (currentUser.getUserGroup().getUserGroupSlug().equals("String_Node_Str")) {
        isAllowToAccess=true;
      }
    }
    if (!isAllowToAccess) {
      throw new ResourceNotFoundException();
    }
  }
  ModelAndView view=new ModelAndView("String_Node_Str");
  view.addObject("String_Node_Str",problem);
  if (isLoggedIn) {
    long userId=(Long)session.getAttribute("String_Node_Str");
    Map<Long,Submission> submissionOfProblems=submissionService.getSubmissionOfProblems(userId,problemId,problemId + 1);
    List<Submission> submissions=submissionService.getSubmissionUsingProblemIdAndUserId(problemId,userId,NUMBER_OF_SUBMISSIONS_PER_PROBLEM);
    List<Language> languages=languageService.getAllLanguages();
    view.addObject("String_Node_Str",submissionOfProblems);
    view.addObject("String_Node_Str",submissions);
    view.addObject("String_Node_Str",languages);
    view.addObject("String_Node_Str",CsrfProtector.getCsrfToken(session));
  }
  return view;
}

Fixed version (ground truth):
/** 
 * 加载试题的详细信息.
 * @param problemId - 试题的唯一标识符
 * @param request - HttpRequest对象
 * @param response - HttpResponse对象
 * @return 包含试题详细信息的ModelAndView对象
 */
@RequestMapping(value="String_Node_Str",method=RequestMethod.GET) public ModelAndView problemView(@PathVariable("String_Node_Str") long problemId,HttpServletRequest request,HttpServletResponse response){
  HttpSession session=request.getSession();
  boolean isLoggedIn=isLoggedIn(session);
  Problem problem=problemService.getProblem(problemId);
  if (problem == null) {
    throw new ResourceNotFoundException();
  }
 else   if (!problem.isPublic()) {
    boolean isAllowToAccess=false;
    if (isLoggedIn) {
      User currentUser=HttpSessionParser.getCurrentUser(session);
      if (currentUser.getUserGroup().getUserGroupSlug().equals("String_Node_Str")) {
        isAllowToAccess=true;
      }
    }
    if (!isAllowToAccess) {
      throw new ResourceNotFoundException();
    }
  }
  ModelAndView view=new ModelAndView("String_Node_Str");
  view.addObject("String_Node_Str",problem);
  if (isLoggedIn) {
    long userId=(Long)session.getAttribute("String_Node_Str");
    Map<Long,Submission> submissionOfProblems=submissionService.getSubmissionOfProblems(userId,problemId,problemId + 1);
    List<Submission> submissions=submissionService.getSubmissionUsingProblemIdAndUserId(problemId,userId,NUMBER_OF_SUBMISSIONS_PER_PROBLEM);
    List<Language> languages=languageService.getAllLanguages();
    view.addObject("String_Node_Str",submissionOfProblems);
    view.addObject("String_Node_Str",submissions);
    view.addObject("String_Node_Str",languages);
    view.addObject("String_Node_Str",CsrfProtector.getCsrfToken(session));
  }
  return view;
}