[Demonstration 1]

[Buggy Method]
public static void addCurrentString(Element e, String dflt, Model m, Resource r, Property p, boolean addLabel) {
    String value = e.getTextContent().trim();
    if (value.isEmpty())
        return;
    String tag = getBCP47(e, dflt, m, r);
    if (tag.equals("bo") && !value.isEmpty()) {
        value = normalizeTibetan(value);
        if (converter.isCombining(value.charAt(0))) {
            addException(m, r, "Unicode string '" + value + "' starts with combining character");
        }
    }
    Literal l = m.createLiteral(value, tag);
    m.add(r, p, l);
    if (addLabel)
        m.add(r, RDFS.label, l);
    if (tag.equals("bo-x-ewts")) {
        List<String> conversionWarnings = new ArrayList<String>();
        String convertedValue = converter.toUnicode(value, conversionWarnings, true);
        if (conversionWarnings.size() > 0) {
            String exceptionString = "Warnings during unicode conversion: " + String.join(", ", conversionWarnings);
            exceptionString += " initial ewts string: " + value;
            addException(m, r, exceptionString);
        } else {
            value = convertedValue;
            tag = "bo";
        }
        l = m.createLiteral(value, tag);
        m.add(r, p, l);
        if (addLabel)
            m.add(r, RDFS.label, l);
    }
}

[Buggy Hunk]
String value = e.getTextContent().trim();

[Patch]
String value = normalizeString(e.getTextContent());

[Demonstration 2]

[Buggy Method]
@Override
public String execute() {
    user = GetUserByIdService.execute(userId);
    return SUCCESS;
}

[Buggy Hunk]
user = GetUserByIdService.execute(userId);

[Patch]
user = GetUserByIdService.execute(id);

[Demonstration 3]

[Buggy Method]
public static ArrayList<Reply> doGroupQuery(Wiki wiki, URLBuilder ub, String tkey, ArrayList<String> titles) {
    ArrayList<Reply> srl = new ArrayList<>();
    LinkedList<String> l = new LinkedList<>(titles);
    while (!l.isEmpty()) {
        ArrayList<String> t = new ArrayList<>();
        for (int i = 0; i < Settings.groupquerymax && l.peek() != null; i++) t.add(l.poll());
        ub.setParams(tkey, URLBuilder.chainProps(t.toArray(new String[0])));
        Reply r = doSingleQuery(wiki, ub);
        if (r != null)
            srl.add(r);
        else
            break;
    }
    return srl;
}

[Buggy Hunk]
LinkedList<String> l = new LinkedList<>(titles);

[Patch]
ArrayDeque<String> l = new ArrayDeque<>(titles);