Program: 87000
Project: 87000
Buggy source:
public static void main(String[] args) throws IOException, InterruptedException, ParseException {
  CommandLineParser parser=new PosixParser();
  CommandLine cmd=null;
  try {
    cmd=parser.parse(options,args);
  }
 catch (  ParseException parseExcep) {
    System.err.println(parseExcep);
    printUsage();
    System.exit(1);
  }
  String host=cmd.getOptionValue(HOST_OPT_LONG);
  int port=defaultPort;
  String portNum=cmd.getOptionValue(PORT_OPT_LONG);
  if (portNum != null) {
    try {
      port=Integer.parseInt(portNum);
    }
 catch (    NumberFormatException e) {
      throw new ParseException("String_Node_Str");
    }
  }
  String username=cmd.getOptionValue(USERNAME_OPT_LONG);
  String password=cmd.getOptionValue(PASSWORD_OPT_LONG);
  NodeProbe probe=null;
  try {
    probe=new NodeProbe(host,port,username,password);
  }
 catch (  IOException ioe) {
    System.err.println("String_Node_Str");
    ioe.printStackTrace();
    System.exit(3);
  }
  if (cmd.getArgs().length < 1) {
    System.err.println("String_Node_Str");
    printUsage();
    System.exit(1);
  }
  NodeCmd nodeCmd=new NodeCmd(probe);
  String[] arguments=cmd.getArgs();
  String cmdName=arguments[0];
  if (cmdName.equals("String_Node_Str")) {
    nodeCmd.printRing(System.out);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    nodeCmd.printInfo(System.out);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    if (arguments.length > 1)     probe.forceTableCleanup(arguments[1]);
 else     probe.forceTableCleanup();
  }
 else   if (cmdName.equals("String_Node_Str") || cmdName.equals("String_Node_Str")) {
    if (arguments.length == 1) {
      if (cmdName.equals("String_Node_Str"))       probe.forceTableCompaction();
 else       probe.forceTableCleanup();
    }
 else {
      String[] columnFamilies=new String[cmd.getArgs().length - 2];
      for (int i=0; i < columnFamilies.length; i++) {
        columnFamilies[i]=cmd.getArgs()[i + 2];
      }
      if (cmdName.equals("String_Node_Str")) {
        probe.forceTableCompaction(arguments[1],columnFamilies);
      }
 else {
        probe.forceTableCleanup(arguments[1],columnFamilies);
      }
    }
  }
 else   if (cmdName.equals("String_Node_Str")) {
    nodeCmd.printColumnFamilyStats(System.out);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    probe.decommission();
  }
 else   if (cmdName.equals("String_Node_Str")) {
    probe.loadBalance();
  }
 else   if (cmdName.equals("String_Node_Str")) {
    if (arguments.length <= 1) {
      System.err.println("String_Node_Str");
    }
    probe.move(arguments[1]);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    if (arguments.length <= 1) {
      System.err.println("String_Node_Str");
    }
    probe.removeToken(arguments[1]);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    String snapshotName="String_Node_Str";
    if (arguments.length > 1) {
      snapshotName=arguments[1];
    }
    probe.takeSnapshot(snapshotName);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    probe.clearSnapshot();
  }
 else   if (cmdName.equals("String_Node_Str")) {
    nodeCmd.printThreadPoolStats(System.out);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    System.out.println(probe.gossipInfo());
  }
 else   if (cmdName.equals("String_Node_Str")) {
    probe.gossipStop();
  }
 else   if (cmdName.equals("String_Node_Str")) {
    probe.gossipStart();
  }
 else   if (cmdName.equals("String_Node_Str")) {
    probe.gossipPurgePersistent();
  }
 else   if (cmdName.equals("String_Node_Str") || cmdName.equals("String_Node_Str")) {
    if (cmd.getArgs().length < 2) {
      System.err.println("String_Node_Str");
      printUsage();
      System.exit(1);
    }
    String[] columnFamilies=new String[cmd.getArgs().length - 2];
    for (int i=0; i < columnFamilies.length; i++) {
      columnFamilies[i]=cmd.getArgs()[i + 2];
    }
    if (cmdName.equals("String_Node_Str"))     probe.forceTableFlush(cmd.getArgs()[1],columnFamilies);
 else     probe.forceTableRepair(cmd.getArgs()[1],columnFamilies);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    try {
      probe.drain();
    }
 catch (    ExecutionException ee) {
      System.err.println("String_Node_Str");
      ee.printStackTrace();
      System.exit(3);
    }
  }
 else   if (cmdName.equals("String_Node_Str")) {
    if (cmd.getArgs().length != 5) {
      System.err.println("String_Node_Str");
    }
    String tableName=cmd.getArgs()[1];
    String cfName=cmd.getArgs()[2];
    int keyCacheCapacity=Integer.valueOf(cmd.getArgs()[3]);
    int rowCacheCapacity=Integer.valueOf(cmd.getArgs()[4]);
    probe.setCacheCapacities(tableName,cfName,keyCacheCapacity,rowCacheCapacity);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    probe.getCompactionThreshold(System.out);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    if (arguments.length < 2) {
      System.err.println("String_Node_Str");
      printUsage();
      System.exit(1);
    }
    int minthreshold=Integer.parseInt(arguments[1]);
    int maxthreshold;
    if (arguments.length > 2) {
      maxthreshold=Integer.parseInt(arguments[2]);
    }
 else {
      maxthreshold=probe.getMaxCompactionThreshold();
    }
    if (minthreshold > maxthreshold) {
      System.err.println("String_Node_Str");
      printUsage();
      System.exit(1);
    }
    if (minthreshold < 2 && maxthreshold != 0) {
      System.err.println("String_Node_Str");
      printUsage();
      System.exit(1);
    }
    probe.setCompactionThreshold(minthreshold,maxthreshold);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    String otherHost=arguments.length > 1 ? arguments[1] : null;
    nodeCmd.printStreamInfo(otherHost == null ? null : InetAddress.getByName(otherHost),System.out);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    String otherHost=arguments[1];
    probe.cancelStreamOut(host);
    System.out.println("String_Node_Str" + otherHost + "String_Node_Str");
    nodeCmd.printStreamInfo(otherHost == null ? null : InetAddress.getByName(otherHost),System.out);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    String mbits=arguments[1];
    probe.setStreamingInMBits(Integer.parseInt(mbits));
  }
 else   if (cmdName.equals("String_Node_Str")) {
    if (arguments.length < 3) {
      System.err.println("String_Node_Str");
      System.exit(1);
    }
    nodeCmd.printCfHistograms(arguments[1],arguments[2],System.out);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    probe.completeBootstrap();
  }
 else {
    System.err.println("String_Node_Str" + cmdName + "String_Node_Str");
    printUsage();
    System.exit(1);
  }
  System.exit(0);
}

Fixed version (ground truth):
public static void main(String[] args) throws IOException, InterruptedException, ParseException {
  CommandLineParser parser=new PosixParser();
  CommandLine cmd=null;
  try {
    cmd=parser.parse(options,args);
  }
 catch (  ParseException parseExcep) {
    System.err.println(parseExcep);
    printUsage();
    System.exit(1);
  }
  String host=cmd.getOptionValue(HOST_OPT_LONG);
  int port=defaultPort;
  String portNum=cmd.getOptionValue(PORT_OPT_LONG);
  if (portNum != null) {
    try {
      port=Integer.parseInt(portNum);
    }
 catch (    NumberFormatException e) {
      throw new ParseException("String_Node_Str");
    }
  }
  String username=cmd.getOptionValue(USERNAME_OPT_LONG);
  String password=cmd.getOptionValue(PASSWORD_OPT_LONG);
  NodeProbe probe=null;
  try {
    probe=new NodeProbe(host,port,username,password);
  }
 catch (  IOException ioe) {
    System.err.println("String_Node_Str");
    ioe.printStackTrace();
    System.exit(3);
  }
  if (cmd.getArgs().length < 1) {
    System.err.println("String_Node_Str");
    printUsage();
    System.exit(1);
  }
  NodeCmd nodeCmd=new NodeCmd(probe);
  String[] arguments=cmd.getArgs();
  String cmdName=arguments[0];
  if (cmdName.equals("String_Node_Str")) {
    nodeCmd.printRing(System.out);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    nodeCmd.printInfo(System.out);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    if (arguments.length > 1)     probe.forceTableCleanup(arguments[1]);
 else     probe.forceTableCleanup();
  }
 else   if (cmdName.equals("String_Node_Str") || cmdName.equals("String_Node_Str")) {
    if (arguments.length == 1) {
      if (cmdName.equals("String_Node_Str"))       probe.forceTableCompaction();
 else       probe.forceTableCleanup();
    }
 else {
      String[] columnFamilies=new String[cmd.getArgs().length - 2];
      for (int i=0; i < columnFamilies.length; i++) {
        columnFamilies[i]=cmd.getArgs()[i + 2];
      }
      if (cmdName.equals("String_Node_Str")) {
        probe.forceTableCompaction(arguments[1],columnFamilies);
      }
 else {
        probe.forceTableCleanup(arguments[1],columnFamilies);
      }
    }
  }
 else   if (cmdName.equals("String_Node_Str")) {
    nodeCmd.printColumnFamilyStats(System.out);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    probe.decommission();
  }
 else   if (cmdName.equals("String_Node_Str")) {
    probe.loadBalance();
  }
 else   if (cmdName.equals("String_Node_Str")) {
    if (arguments.length <= 1) {
      System.err.println("String_Node_Str");
    }
    probe.move(arguments[1]);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    if (arguments.length <= 1) {
      System.err.println("String_Node_Str");
    }
    probe.removeToken(arguments[1]);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    String snapshotName="String_Node_Str";
    if (arguments.length > 1) {
      snapshotName=arguments[1];
    }
    probe.takeSnapshot(snapshotName);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    probe.clearSnapshot();
  }
 else   if (cmdName.equals("String_Node_Str")) {
    nodeCmd.printThreadPoolStats(System.out);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    System.out.println(probe.gossipInfo());
  }
 else   if (cmdName.equals("String_Node_Str")) {
    probe.gossipStop();
  }
 else   if (cmdName.equals("String_Node_Str")) {
    probe.gossipStart();
  }
 else   if (cmdName.equals("String_Node_Str")) {
    probe.gossipPurgePersistent();
  }
 else   if (cmdName.equals("String_Node_Str") || cmdName.equals("String_Node_Str")) {
    if (cmd.getArgs().length < 2) {
      System.err.println("String_Node_Str");
      printUsage();
      System.exit(1);
    }
    String[] columnFamilies=new String[cmd.getArgs().length - 2];
    for (int i=0; i < columnFamilies.length; i++) {
      columnFamilies[i]=cmd.getArgs()[i + 2];
    }
    if (cmdName.equals("String_Node_Str"))     probe.forceTableFlush(cmd.getArgs()[1],columnFamilies);
 else     probe.forceTableRepair(cmd.getArgs()[1],columnFamilies);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    try {
      probe.drain();
    }
 catch (    ExecutionException ee) {
      System.err.println("String_Node_Str");
      ee.printStackTrace();
      System.exit(3);
    }
  }
 else   if (cmdName.equals("String_Node_Str")) {
    if (cmd.getArgs().length != 5) {
      System.err.println("String_Node_Str");
    }
    String tableName=cmd.getArgs()[1];
    String cfName=cmd.getArgs()[2];
    int keyCacheCapacity=Integer.valueOf(cmd.getArgs()[3]);
    int rowCacheCapacity=Integer.valueOf(cmd.getArgs()[4]);
    probe.setCacheCapacities(tableName,cfName,keyCacheCapacity,rowCacheCapacity);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    probe.getCompactionThreshold(System.out);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    if (arguments.length < 2) {
      System.err.println("String_Node_Str");
      printUsage();
      System.exit(1);
    }
    int minthreshold=Integer.parseInt(arguments[1]);
    int maxthreshold;
    if (arguments.length > 2) {
      maxthreshold=Integer.parseInt(arguments[2]);
    }
 else {
      maxthreshold=probe.getMaxCompactionThreshold();
    }
    if (minthreshold > maxthreshold) {
      System.err.println("String_Node_Str");
      printUsage();
      System.exit(1);
    }
    if (minthreshold < 2 && maxthreshold != 0) {
      System.err.println("String_Node_Str");
      printUsage();
      System.exit(1);
    }
    probe.setCompactionThreshold(minthreshold,maxthreshold);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    String otherHost=arguments.length > 1 ? arguments[1] : null;
    nodeCmd.printStreamInfo(otherHost == null ? null : InetAddress.getByName(otherHost),System.out);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    String otherHost=arguments[1];
    probe.cancelStreamOut(otherHost);
    System.out.println("String_Node_Str" + otherHost + "String_Node_Str");
    nodeCmd.printStreamInfo(otherHost == null ? null : InetAddress.getByName(otherHost),System.out);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    String mbits=arguments[1];
    probe.setStreamingInMBits(Integer.parseInt(mbits));
  }
 else   if (cmdName.equals("String_Node_Str")) {
    if (arguments.length < 3) {
      System.err.println("String_Node_Str");
      System.exit(1);
    }
    nodeCmd.printCfHistograms(arguments[1],arguments[2],System.out);
  }
 else   if (cmdName.equals("String_Node_Str")) {
    probe.completeBootstrap();
  }
 else {
    System.err.println("String_Node_Str" + cmdName + "String_Node_Str");
    printUsage();
    System.exit(1);
  }
  System.exit(0);
}