Program: 48479
Project: 48479
Buggy source:
public void handle(HttpPostCommand command){
  try {
    String uri=command.getURI();
    if (uri.startsWith(URI_MAPS)) {
      int indexEnd=uri.indexOf('/',URI_MAPS.length());
      String mapName=uri.substring(URI_MAPS.length(),indexEnd);
      String key=uri.substring(indexEnd + 1);
      byte[] data=command.getData();
      textCommandService.put(mapName,key,new RestValue(data,command.getContentType()),0);
      command.setResponse(HttpCommand.RES_204);
    }
 else     if (uri.startsWith(URI_MANCENTER_CHANGE_URL)) {
      if (textCommandService.getNode().getGroupProperties().MC_URL_CHANGE_ENABLED.getBoolean()) {
        byte[] res=HttpCommand.RES_204;
        byte[] data=command.getData();
        String[] strList=new String(data).split("String_Node_Str");
        String cluster=URLDecoder.decode(strList[0],"String_Node_Str");
        String pass=URLDecoder.decode(strList[1],"String_Node_Str");
        String url=URLDecoder.decode(strList[2],"String_Node_Str");
        ManagementCenterService managementCenterService=textCommandService.getNode().getManagementCenterService();
        if (managementCenterService != null) {
          res=managementCenterService.changeWebServerUrlOverCluster(cluster,pass,url);
        }
        command.setResponse(res);
      }
 else {
        command.setResponse(HttpCommand.RES_503);
      }
    }
 else     if (uri.startsWith(URI_QUEUES)) {
      String queueName=null;
      String simpleValue=null;
      String suffix;
      if (uri.endsWith("String_Node_Str")) {
        suffix=uri.substring(URI_QUEUES.length(),uri.length() - 1);
      }
 else {
        suffix=uri.substring(URI_QUEUES.length(),uri.length());
      }
      int indexSlash=suffix.lastIndexOf("String_Node_Str");
      if (indexSlash == -1) {
        queueName=suffix;
      }
 else {
        queueName=suffix.substring(0,indexSlash);
        simpleValue=suffix.substring(indexSlash + 1,suffix.length());
      }
      byte[] data;
      byte[] contentType;
      if (simpleValue == null) {
        data=command.getData();
        contentType=command.getContentType();
      }
 else {
        data=simpleValue.getBytes();
        contentType=QUEUE_SIMPLE_VALUE_CONTENT_TYPE;
      }
      boolean offerResult=textCommandService.offer(queueName,new RestValue(data,contentType));
      if (offerResult) {
        command.setResponse(HttpCommand.RES_204);
      }
 else {
        command.setResponse(HttpCommand.RES_503);
      }
    }
 else {
      command.setResponse(HttpCommand.RES_400);
    }
  }
 catch (  Exception e) {
    command.setResponse(HttpCommand.RES_500);
  }
  textCommandService.sendResponse(command);
}

Fixed version (ground truth):
public void handle(HttpPostCommand command){
  try {
    String uri=command.getURI();
    if (uri.startsWith(URI_MAPS)) {
      int indexEnd=uri.indexOf('/',URI_MAPS.length());
      String mapName=uri.substring(URI_MAPS.length(),indexEnd);
      String key=uri.substring(indexEnd + 1);
      byte[] data=command.getData();
      textCommandService.put(mapName,key,new RestValue(data,command.getContentType()),-1);
      command.setResponse(HttpCommand.RES_204);
    }
 else     if (uri.startsWith(URI_MANCENTER_CHANGE_URL)) {
      if (textCommandService.getNode().getGroupProperties().MC_URL_CHANGE_ENABLED.getBoolean()) {
        byte[] res=HttpCommand.RES_204;
        byte[] data=command.getData();
        String[] strList=new String(data).split("String_Node_Str");
        String cluster=URLDecoder.decode(strList[0],"String_Node_Str");
        String pass=URLDecoder.decode(strList[1],"String_Node_Str");
        String url=URLDecoder.decode(strList[2],"String_Node_Str");
        ManagementCenterService managementCenterService=textCommandService.getNode().getManagementCenterService();
        if (managementCenterService != null) {
          res=managementCenterService.changeWebServerUrlOverCluster(cluster,pass,url);
        }
        command.setResponse(res);
      }
 else {
        command.setResponse(HttpCommand.RES_503);
      }
    }
 else     if (uri.startsWith(URI_QUEUES)) {
      String queueName=null;
      String simpleValue=null;
      String suffix;
      if (uri.endsWith("String_Node_Str")) {
        suffix=uri.substring(URI_QUEUES.length(),uri.length() - 1);
      }
 else {
        suffix=uri.substring(URI_QUEUES.length(),uri.length());
      }
      int indexSlash=suffix.lastIndexOf("String_Node_Str");
      if (indexSlash == -1) {
        queueName=suffix;
      }
 else {
        queueName=suffix.substring(0,indexSlash);
        simpleValue=suffix.substring(indexSlash + 1,suffix.length());
      }
      byte[] data;
      byte[] contentType;
      if (simpleValue == null) {
        data=command.getData();
        contentType=command.getContentType();
      }
 else {
        data=simpleValue.getBytes();
        contentType=QUEUE_SIMPLE_VALUE_CONTENT_TYPE;
      }
      boolean offerResult=textCommandService.offer(queueName,new RestValue(data,contentType));
      if (offerResult) {
        command.setResponse(HttpCommand.RES_204);
      }
 else {
        command.setResponse(HttpCommand.RES_503);
      }
    }
 else {
      command.setResponse(HttpCommand.RES_400);
    }
  }
 catch (  Exception e) {
    command.setResponse(HttpCommand.RES_500);
  }
  textCommandService.sendResponse(command);
}