Program: 107223
Project: 107223
Buggy source:
public void dispatchCreateCmd(BaseAsyncCreateCmd cmd,Map<String,String> params){
  String errorMsg="String_Node_Str";
  setupParameters(cmd,params);
  try {
    cmd.create();
  }
 catch (  Throwable t) {
    if (t instanceof InvalidParameterValueException || t instanceof IllegalArgumentException) {
      s_logger.info(t.getMessage());
      throw new ServerApiException(BaseCmd.PARAM_ERROR,t.getMessage());
    }
 else     if (t instanceof PermissionDeniedException) {
      s_logger.info("String_Node_Str" + t.getMessage());
      throw new ServerApiException(BaseCmd.ACCOUNT_ERROR,t.getMessage());
    }
 else     if (t instanceof AccountLimitException) {
      s_logger.info(t.getMessage());
      throw new ServerApiException(BaseCmd.ACCOUNT_RESOURCE_LIMIT_ERROR,t.getMessage());
    }
 else     if (t instanceof InsufficientCapacityException) {
      s_logger.info(t.getMessage());
      throw new ServerApiException(BaseCmd.INSUFFICIENT_CAPACITY_ERROR,t.getMessage());
    }
 else     if (t instanceof ResourceAllocationException) {
      s_logger.info(t.getMessage());
      throw new ServerApiException(BaseCmd.RESOURCE_ALLOCATION_ERROR,t.getMessage());
    }
 else     if (t instanceof ResourceUnavailableException) {
      s_logger.warn("String_Node_Str",t);
      throw new ServerApiException(BaseCmd.RESOURCE_UNAVAILABLE_ERROR,t.getMessage());
    }
 else     if (t instanceof AsyncCommandQueued) {
      throw (AsyncCommandQueued)t;
    }
 else     if (t instanceof ServerApiException) {
      s_logger.warn(t.getClass() + "String_Node_Str" + ((ServerApiException)t).getDescription());
      if (UserContext.current().getCaller().getType() == Account.ACCOUNT_TYPE_ADMIN) {
        throw new ServerApiException(BaseCmd.INTERNAL_ERROR,errorMsg);
      }
 else {
        throw new ServerApiException(BaseCmd.INTERNAL_ERROR,BaseCmd.USER_ERROR_MESSAGE);
      }
    }
 else {
      s_logger.error("String_Node_Str" + cmd.getClass().getSimpleName() + "String_Node_Str",t);
      if (UserContext.current().getCaller().getType() == Account.ACCOUNT_TYPE_ADMIN) {
        throw new ServerApiException(BaseCmd.INTERNAL_ERROR,t.getMessage());
      }
 else {
        throw new ServerApiException(BaseCmd.INTERNAL_ERROR,BaseCmd.USER_ERROR_MESSAGE);
      }
    }
  }
}

Fixed version (ground truth):
public void dispatchCreateCmd(BaseAsyncCreateCmd cmd,Map<String,String> params){
  String errorMsg="String_Node_Str";
  setupParameters(cmd,params);
  try {
    cmd.create();
  }
 catch (  Throwable t) {
    if (t instanceof InvalidParameterValueException || t instanceof IllegalArgumentException) {
      s_logger.info(t.getMessage());
      throw new ServerApiException(BaseCmd.PARAM_ERROR,t.getMessage());
    }
 else     if (t instanceof PermissionDeniedException) {
      s_logger.info("String_Node_Str" + t.getMessage());
      throw new ServerApiException(BaseCmd.ACCOUNT_ERROR,t.getMessage());
    }
 else     if (t instanceof AccountLimitException) {
      s_logger.info(t.getMessage());
      throw new ServerApiException(BaseCmd.ACCOUNT_RESOURCE_LIMIT_ERROR,t.getMessage());
    }
 else     if (t instanceof InsufficientCapacityException) {
      s_logger.info(t.getMessage());
      throw new ServerApiException(BaseCmd.INSUFFICIENT_CAPACITY_ERROR,t.getMessage());
    }
 else     if (t instanceof ResourceAllocationException) {
      s_logger.info(t.getMessage());
      throw new ServerApiException(BaseCmd.RESOURCE_ALLOCATION_ERROR,t.getMessage());
    }
 else     if (t instanceof ResourceUnavailableException) {
      s_logger.warn("String_Node_Str",t);
      throw new ServerApiException(BaseCmd.RESOURCE_UNAVAILABLE_ERROR,t.getMessage());
    }
 else     if (t instanceof AsyncCommandQueued) {
      throw (AsyncCommandQueued)t;
    }
 else     if (t instanceof ServerApiException) {
      s_logger.warn(t.getClass() + "String_Node_Str" + ((ServerApiException)t).getDescription());
      if (UserContext.current().getCaller().getType() == Account.ACCOUNT_TYPE_ADMIN) {
        throw new ServerApiException(BaseCmd.INTERNAL_ERROR,errorMsg.length() > 0 ? errorMsg : ((ServerApiException)t).getDescription());
      }
 else {
        throw new ServerApiException(BaseCmd.INTERNAL_ERROR,BaseCmd.USER_ERROR_MESSAGE);
      }
    }
 else {
      s_logger.error("String_Node_Str" + cmd.getClass().getSimpleName() + "String_Node_Str",t);
      if (UserContext.current().getCaller().getType() == Account.ACCOUNT_TYPE_ADMIN) {
        throw new ServerApiException(BaseCmd.INTERNAL_ERROR,t.getMessage());
      }
 else {
        throw new ServerApiException(BaseCmd.INTERNAL_ERROR,BaseCmd.USER_ERROR_MESSAGE);
      }
    }
  }
}