[Demonstration 1]

[Buggy Method]
public static String toJson(Map<String, List<G_PropertyMatchDescriptor>> map) throws IOException {
    return SerializationHelper.toJson(map, G_PropertyMatchDescriptor.getClassSchema());
}

[Buggy Hunk]
public static String toJson(Map<String, List<G_PropertyMatchDescriptor>> map) throws IOException {

[Patch]
public static String toJson(final Map<String, List<G_PropertyMatchDescriptor>> map) throws IOException {

[Demonstration 2]

[Buggy Method]
private Citation pubMedResultToCitation(Result result) {
    Citation newCitation = new Citation();
    newCitation.setTitle(result.getTitle());
    newCitation.setAbstracT(result.getAbstractText().trim());
    newCitation.setId(result.getId());
    newCitation.setAuthorsText(result.getAuthorString());
    // TODO: Authors.
    return newCitation;
}

[Buggy Hunk]
newCitation.setAbstracT(result.getAbstractText().trim());

[Patch]
newCitation.setAbstracT(result.getAbstractText());

[Demonstration 3]

[Buggy Method]
public static long parseCommandNumber(String line, String cmd) {
    line = line.trim();
    long result = -1;
    int startPos = line.lastIndexOf(cmd + " ");
    if (startPos >= 0) {
        int begOfNr = startPos + 1;
        int endOfNr = line.indexOf(" ", begOfNr + 1);
        if (endOfNr < begOfNr) {
            endOfNr = line.length();
        }
        String nr = line.substring(begOfNr + 1, endOfNr).trim();
        try {
            result = Long.parseLong(nr);
        } catch (Throwable th) {
            //				Log.error("Invalid number when parsing number from command:"+line,th);
        }
    }
    return result;
}

[Buggy Hunk]
int begOfNr = startPos + 1;

[Patch]
int begOfNr = startPos + cmd.length();