[Demonstration 1]

[Buggy Method]
private static void parseIncludeVariables(Document doc) throws Exception {
    // parse include document in source server xml
    XPath xPath = XPathFactory.newInstance().newXPath();
    NodeList nodeList = (NodeList) xPath.compile("/server/include").evaluate(doc, XPathConstants.NODESET);
    for (int i = 0; i < nodeList.getLength(); i++) {
        String nodeValue = nodeList.item(i).getAttributes().getNamedItem("location").getNodeValue();
        if (!nodeValue.isEmpty()) {
            Document docIncl = getIncludeDoc(nodeValue);
            if (docIncl != null) {
                parseVariables(docIncl);
                // handle nested include elements
                parseIncludeVariables(docIncl);
            }
        }
    }
}

[Buggy Hunk]
private static void parseIncludeVariables(Document doc) throws Exception {

[Patch]
private void parseIncludeVariables(Document doc) throws Exception {

[Demonstration 2]

[Buggy Method]
private String extractName(String line) {
    String userName = "";
    Document doc = Jsoup.parse(line);
    Elements select = doc.select("a");
    List<Element> elements = new ArrayList<>();
    select.forEach((a) -> elements.add(a));
    // start from behind to det last aut and date.
    Collections.reverse(elements);
    big: for (int i = 0; i < elements.size(); i++) {
        Element elem = elements.get(i);
        String title = elem.attr("title");
        if (title.startsWith("Spezial")) {
            userName = title.split(":")[1].split("/")[1];
        }
        if (title.startsWith("Benut")) {
            userName = title.split(":")[1];
        }
        if (!title.equals(""))
            break big;
    }
    // specific togerman wiki .
    if (userName.contains(" (Seite nicht vorhanden)"))
        userName = userName.substring(0, userName.indexOf(" (Seite nicht vorhanden)"));
    return userName;
}

[Buggy Hunk]
private String extractName(String line) {

[Patch]
protected String extractName(String line) {

[Demonstration 3]

[Buggy Method]
@Override
public synchronized void notifyPlenScanComplete(@NonNull List<String> addresses) {
    dismissDialogFragment(SCANNING_DIALOG);
    dismissDialogFragment(SELECT_PLEN_DIALOG);
    String defaultAddress = mPref.defaultPlenAddress().get();
    CompositeSubscription subscriptions = new CompositeSubscription();
    SelectPlenDialogFragment fragment = SelectPlenDialogFragment_.builder().addresses(addresses.toArray(new String[addresses.size()])).defaultAddress(defaultAddress).build();
    fragment.onDeviceSelectEvent().lift(Operators.composite(subscriptions)).subscribe(i -> mPref.edit().defaultPlenAddress().put(addresses.get(i)).apply());
    fragment.cancelEvent().lift(Operators.composite(subscriptions)).subscribe(v -> mPref.edit().defaultPlenAddress().put(defaultAddress).apply());
    fragment.okEvent().lift(Operators.composite(subscriptions)).subscribe(v -> Optional.ofNullable(mPref.defaultPlenAddress().get()).filter(address -> !address.isEmpty()).ifPresent(mPresenter::connectPlen));
    fragment.rescanEvent().lift(Operators.composite(subscriptions)).subscribe(v -> mPresenter.startScan());
    mFragmentManager.ifPresent(m -> fragment.show(m, LOCATION_SETTING_DIALOG));
    mSubscriptions.add(subscriptions);
}

[Buggy Hunk]
mFragmentManager.ifPresent(m -> fragment.show(m, LOCATION_SETTING_DIALOG));

[Patch]
mFragmentManager.ifPresent(m -> fragment.show(m, SELECT_PLEN_DIALOG));