[Demonstration 1]

[Buggy Method]
private static Request getRequest(String uri) {
    return new ApacheRequest(uri).header(HttpHeaders.USER_AGENT, RtGithub.USER_AGENT).header(HttpHeaders.ACCEPT, MediaType.APPLICATION_JSON).header(HttpHeaders.CONTENT_TYPE, MediaType.APPLICATION_JSON);
}

[Buggy Hunk]
private static Request getRequest(String uri) {

[Patch]
private static Request getRequest(final String uri) {

[Demonstration 2]

[Buggy Method]
private void winnerIs(Squad crew1, Squad crew2) {
    String winner;
    String looser;
    if (crew1.hasAliveWarriors()) {
        winner = crew1.getName();
        looser = crew2.getName();
    } else {
        winner = crew2.getName();
        looser = crew1.getName();
    }
    msg.append("Отряд ").append(winner).append(" победил, уничтожив отряд ").append(looser);
    notifyObserver();
}

[Buggy Hunk]
msg.append("Отряд ").append(winner).append(" победил, уничтожив отряд ").append(looser);

[Patch]
msg.append("Отряд ").append(winner).append(" победил, уничтожив отряд ").append(looser).append("\n");

[Demonstration 3]

[Buggy Method]
@Override
public Uri insert(Uri uri, ContentValues values) {
    IProviderOperation operation = operations.get(uriMatcher.match(uri));
    if (operation != null) {
        SQLiteDatabase db = mDatabaseHelper.getWritableDatabase();
        long rowId = operation.insert(db, values);
        if (rowId > 0) {
            Uri newUri = ContentUris.withAppendedId(operation.getContentUri(), rowId);
            getContext().getContentResolver().notifyChange(newUri, null);
            return newUri;
        }
        throw new SQLException("Failed to insert row into " + uri);
    }
    throw new IllegalArgumentException("Unknown URI " + uri);
}

[Buggy Hunk]
if (rowId > 0) {

[Patch]
if (rowId >= 0) {