[Demonstration 1]

[Buggy Method]
@Override
public void apply(StateManager stateManager) {
    Gdx.app.log("MainControlScreen", "test");
}

[Buggy Hunk]
Gdx.app.log("MainControlScreen", "test");

[Patch]
game.getStateManager().win();

[Demonstration 2]

[Buggy Method]
private boolean checkFile(long l) {
    DateTime dateTime = new DateTime(l);
    int hour = dateTime.getHourOfDay();
    String date = dateTime.toString("yyyy-MM-dd");
    Path startingDir = Paths.get(config.basePath + "/" + date + "/" + hour);
    boolean exist = Files.exists(startingDir, LinkOption.NOFOLLOW_LINKS);
    if (exist) {
        try {
            List<Path> result = new LinkedList<Path>();
            Files.walkFileTree(startingDir, new FindJavaVisitor(result));
            if (result.size() == 10) {
                return true;
            }
        } catch (IOException e) {
            e.printStackTrace();
        }
        log.info("try next file: not exist!");
    }
    return false;
}

[Buggy Hunk]
Path startingDir = Paths.get(config.basePath + "/" + date + "/" + hour);

[Patch]
Path startingDir = Paths.get(config.basePath + "/" + date + "/" + String.format("%02d", hour));

[Demonstration 3]

[Buggy Method]
private static HighlightHTMLReportParams parseArgs(final String[] args) {
    int i = 0;
    HighlightHTMLReportParams params = new HighlightHTMLReportParams();
    Path root = Paths.get(".");
    while (i < args.length) {
        switch(args[i]) {
            case "-o":
                if (++i >= args.length)
                    usage();
                params.reportDirectory = root.resolve(args[i]).toFile();
                break;
            case "-c":
                if (++i >= args.length)
                    usage();
                PathMatcher cpm = FileSystems.getDefault().getPathMatcher("glob:" + args[i]);
                findFiles(root, cpm, params.classesDirectories);
                break;
            case "-s":
                if (++i >= args.length)
                    usage();
                PathMatcher spm = FileSystems.getDefault().getPathMatcher("glob:" + args[i]);
                findFiles(root, spm, params.sourceDirectories);
                break;
            case "-e":
                if (++i >= args.length)
                    usage();
                PathMatcher epm = FileSystems.getDefault().getPathMatcher("glob:" + args[i]);
                findFiles(root, epm, params.executionDataFiles);
                break;
            case "-t":
                if (++i >= args.length)
                    usage();
                params.title = args[i];
                break;
            case "-p":
                if (++i >= args.length)
                    usage();
                params.parseParamsFile = root.resolve(args[i]).toFile();
                break;
            default:
                root = Paths.get(args[i]).toAbsolutePath().normalize();
        }
        ++i;
    }
    if (params.title.isEmpty())
        params.title = root.toAbsolutePath().normalize().getFileName().toString();
    return params;
}

[Buggy Hunk]
Path root = Paths.get(".");

[Patch]
Path root = Paths.get(System.getProperty("user.dir"));