package defpackage;

import defpackage.m09;

/* JADX INFO: loaded from: classes2.dex */
class f09 extends m09.b {
    public final /* synthetic */ g09 j;

    /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
    public f09(g09 g09Var, m09 m09Var, CharSequence charSequence) {
        super(m09Var, charSequence);
        this.j = g09Var;
    }

    @Override // m09.b
    public final int b(int i) {
        return this.j.a.length() + i;
    }

    /* JADX WARN: Code restructure failed: missing block: B:8:0x0022, code lost:
    
        r8 = r8 + 1;
     */
    @Override // m09.b
    /*
        Code decompiled incorrectly, please refer to instructions dump.
    */
    public final int c(int i) {
        g09 g09Var = this.j;
        int length = g09Var.a.length();
        CharSequence charSequence = this.c;
        int length2 = charSequence.length() - length;
        while (i <= length2) {
            for (int i2 = 0; i2 < length; i2++) {
                if (charSequence.charAt(i2 + i) != g09Var.a.charAt(i2)) {
                    break;
                }
            }
            return i;
        }
        return -1;
    }
}
