Program: 176805
Project: 176805
Buggy source:
/** 
 * Load cassandra specific data.
 * @throws TException the t exception
 * @throws InvalidRequestException the invalid request exception
 * @throws UnavailableException the unavailable exception
 * @throws TimedOutException the timed out exception
 * @throws SchemaDisagreementException the schema disagreement exception
 */
private static void loadData() throws TException, InvalidRequestException, UnavailableException, TimedOutException, SchemaDisagreementException {
  KsDef ksDef=null;
  CfDef user_Def=new CfDef();
  user_Def.name="String_Node_Str";
  user_Def.keyspace=_KEYSPACE;
  user_Def.setComparator_type("String_Node_Str");
  user_Def.setDefault_validation_class("String_Node_Str");
  CfDef person_Def=new CfDef();
  person_Def.name="String_Node_Str";
  person_Def.keyspace=_KEYSPACE;
  person_Def.setComparator_type("String_Node_Str");
  person_Def.setDefault_validation_class("String_Node_Str");
  ColumnDef columnDef=new ColumnDef(ByteBuffer.wrap("String_Node_Str".getBytes()),"String_Node_Str");
  person_Def.addToColumn_metadata(columnDef);
  CfDef address_Def=new CfDef();
  address_Def.name="String_Node_Str";
  address_Def.keyspace=_KEYSPACE;
  ColumnDef street=new ColumnDef(ByteBuffer.wrap("String_Node_Str".getBytes()),"String_Node_Str");
  street.index_type=IndexType.KEYS;
  address_Def.addToColumn_metadata(street);
  ColumnDef personId=new ColumnDef(ByteBuffer.wrap("String_Node_Str".getBytes()),"String_Node_Str");
  personId.index_type=IndexType.KEYS;
  address_Def.addToColumn_metadata(personId);
  List<CfDef> cfDefs=new ArrayList<CfDef>();
  cfDefs.add(user_Def);
  cfDefs.add(person_Def);
  cfDefs.add(address_Def);
  try {
    ksDef=CassandraCli.client.describe_keyspace(_KEYSPACE);
    CassandraCli.client.set_keyspace(_KEYSPACE);
    List<CfDef> cfDefn=ksDef.getCf_defs();
    for (    CfDef cfDef1 : cfDefn) {
      if (cfDef1.getName().equalsIgnoreCase("String_Node_Str")) {
        CassandraCli.client.system_drop_column_family("String_Node_Str");
      }
      if (cfDef1.getName().equalsIgnoreCase("String_Node_Str")) {
        CassandraCli.client.system_drop_column_family("String_Node_Str");
      }
      if (cfDef1.getName().equalsIgnoreCase("String_Node_Str")) {
        CassandraCli.client.system_drop_column_family("String_Node_Str");
      }
    }
    CassandraCli.client.system_add_column_family(user_Def);
    CassandraCli.client.system_add_column_family(person_Def);
    CassandraCli.client.system_add_column_family(address_Def);
  }
 catch (  NotFoundException e) {
    ksDef=new KsDef(_KEYSPACE,"String_Node_Str",cfDefs);
    Map<String,String> strategy_options=new HashMap<String,String>();
    strategy_options.put("String_Node_Str","String_Node_Str");
    ksDef.setStrategy_options(strategy_options);
    CassandraCli.client.system_add_keyspace(ksDef);
  }
  CassandraCli.client.set_keyspace(_KEYSPACE);
}

Fixed version (ground truth):
/** 
 * Load cassandra specific data.
 * @throws TException the t exception
 * @throws InvalidRequestException the invalid request exception
 * @throws UnavailableException the unavailable exception
 * @throws TimedOutException the timed out exception
 * @throws SchemaDisagreementException the schema disagreement exception
 */
private static void loadData() throws TException, InvalidRequestException, UnavailableException, TimedOutException, SchemaDisagreementException {
  KsDef ksDef=null;
  CfDef user_Def=new CfDef();
  user_Def.name="String_Node_Str";
  user_Def.keyspace=_KEYSPACE;
  user_Def.setComparator_type("String_Node_Str");
  user_Def.setDefault_validation_class("String_Node_Str");
  ColumnDef authorDef=new ColumnDef(ByteBuffer.wrap("String_Node_Str".getBytes()),"String_Node_Str");
  authorDef.index_type=IndexType.KEYS;
  ColumnDef publicationDef=new ColumnDef(ByteBuffer.wrap("String_Node_Str".getBytes()),"String_Node_Str");
  publicationDef.index_type=IndexType.KEYS;
  user_Def.addToColumn_metadata(authorDef);
  user_Def.addToColumn_metadata(publicationDef);
  CfDef person_Def=new CfDef();
  person_Def.name="String_Node_Str";
  person_Def.keyspace=_KEYSPACE;
  person_Def.setComparator_type("String_Node_Str");
  person_Def.setDefault_validation_class("String_Node_Str");
  ColumnDef columnDef=new ColumnDef(ByteBuffer.wrap("String_Node_Str".getBytes()),"String_Node_Str");
  person_Def.addToColumn_metadata(columnDef);
  CfDef address_Def=new CfDef();
  address_Def.name="String_Node_Str";
  address_Def.keyspace=_KEYSPACE;
  ColumnDef street=new ColumnDef(ByteBuffer.wrap("String_Node_Str".getBytes()),"String_Node_Str");
  street.index_type=IndexType.KEYS;
  address_Def.addToColumn_metadata(street);
  ColumnDef personId=new ColumnDef(ByteBuffer.wrap("String_Node_Str".getBytes()),"String_Node_Str");
  personId.index_type=IndexType.KEYS;
  address_Def.addToColumn_metadata(personId);
  List<CfDef> cfDefs=new ArrayList<CfDef>();
  cfDefs.add(user_Def);
  cfDefs.add(person_Def);
  cfDefs.add(address_Def);
  try {
    ksDef=CassandraCli.client.describe_keyspace(_KEYSPACE);
    CassandraCli.client.set_keyspace(_KEYSPACE);
    List<CfDef> cfDefn=ksDef.getCf_defs();
    for (    CfDef cfDef1 : cfDefn) {
      if (cfDef1.getName().equalsIgnoreCase("String_Node_Str")) {
        CassandraCli.client.system_drop_column_family("String_Node_Str");
      }
      if (cfDef1.getName().equalsIgnoreCase("String_Node_Str")) {
        CassandraCli.client.system_drop_column_family("String_Node_Str");
      }
      if (cfDef1.getName().equalsIgnoreCase("String_Node_Str")) {
        CassandraCli.client.system_drop_column_family("String_Node_Str");
      }
    }
    CassandraCli.client.system_add_column_family(user_Def);
    CassandraCli.client.system_add_column_family(person_Def);
    CassandraCli.client.system_add_column_family(address_Def);
  }
 catch (  NotFoundException e) {
    ksDef=new KsDef(_KEYSPACE,"String_Node_Str",cfDefs);
    Map<String,String> strategy_options=new HashMap<String,String>();
    strategy_options.put("String_Node_Str","String_Node_Str");
    ksDef.setStrategy_options(strategy_options);
    CassandraCli.client.system_add_keyspace(ksDef);
  }
  CassandraCli.client.set_keyspace(_KEYSPACE);
}