[Demonstration 1]

[Buggy Method]
public static void initFamilyIdSet() {
    String str = FamilyCommand.familyId.replaceAll("( )+", "");
    String familyIds = "";
    File f = new File(str);
    if (!f.isFile()) {
        familyIds = str;
    } else {
        try {
            FileInputStream fstream = new FileInputStream(f);
            DataInputStream in = new DataInputStream(new FileInputStream(f));
            BufferedReader br = new BufferedReader(new InputStreamReader(in));
            while ((str = br.readLine()) != null) {
                if (str.isEmpty()) {
                    continue;
                }
                familyIds += str + ",";
            }
            br.close();
            in.close();
            fstream.close();
        } catch (Exception e) {
            ErrorManager.send(e);
        }
    }
    String[] tempArray = familyIds.split(",");
    for (String id : tempArray) {
        userFamilyIdSet.add(id.toLowerCase());
    }
}

[Buggy Hunk]
userFamilyIdSet.add(id.toLowerCase());

[Patch]
userFamilyIdSet.add(id);

[Demonstration 2]

[Buggy Method]
@Override
public void actionPerformed(ActionEvent e) {
    Object src = e.getSource();
    if (src == begin)
        l = new Locked("LOCKED");
    else if (src == back)
        c.changePanel("3");
}

[Buggy Hunk]
l = new Locked("LOCKED");

[Patch]
l = new Locked("LOCKED", c);

[Demonstration 3]

[Buggy Method]
private void loadConfiguration() {
    try {
        FileInputStream fis = new FileInputStream(CONFIG_FILE);
        prop.loadFromXML(fis);
    } catch (InvalidPropertiesFormatException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
    } catch (IOException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
    }
    // prop.list(System.out); //DEBUG
}

[Buggy Hunk]
FileInputStream fis = new FileInputStream(CONFIG_FILE);

[Patch]
FileInputStream fis = new FileInputStream(ConstantValue.CONFIG_FILE);