package U5;

import A6.n;
import O6.p;
import Z6.InterfaceC0382w;
import c7.K;
import com.google.android.gms.internal.measurement.C1;
import y5.C1763h;

/* JADX INFO: loaded from: classes.dex */
public final class j extends G6.i implements p {

    /* JADX INFO: renamed from: u, reason: collision with root package name */
    public Object f6791u;

    /* JADX INFO: renamed from: v, reason: collision with root package name */
    public int f6792v;

    /* JADX INFO: renamed from: w, reason: collision with root package name */
    public final /* synthetic */ k f6793w;

    /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
    public j(k kVar, E6.d dVar) {
        super(2, dVar);
        this.f6793w = kVar;
    }

    @Override // O6.p
    public final Object k(Object obj, Object obj2) {
        return ((j) m((E6.d) obj2, (InterfaceC0382w) obj)).p(n.f457a);
    }

    @Override // G6.a
    public final E6.d m(E6.d dVar, Object obj) {
        return new j(this.f6793w, dVar);
    }

    /* JADX WARN: Code restructure failed: missing block: B:19:0x0055, code lost:
    
        if (r2.f(r1, r6) == r0) goto L20;
     */
    @Override // G6.a
    /*
        Code decompiled incorrectly, please refer to instructions dump.
    */
    public final Object p(Object obj) throws Throwable {
        Object objA;
        F6.a aVar = F6.a.f2580q;
        int i = this.f6792v;
        k kVar = this.f6793w;
        if (i == 0) {
            C1.N(obj);
            this.f6792v = 1;
            objA = kVar.f6794d.a(this);
            if (objA != aVar) {
            }
            return aVar;
        }
        if (i != 1) {
            if (i != 2) {
                throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine");
            }
            C1.N(obj);
            return n.f457a;
        }
        C1.N(obj);
        objA = ((A6.j) obj).f449q;
        if (!(objA instanceof A6.i)) {
            C1763h c1763h = new C1763h(h.f6786r);
            K k8 = kVar.f6795e;
            k8.getClass();
            k8.g(null, c1763h);
        }
        Throwable thA = A6.j.a(objA);
        if (thA != null) {
            this.f6791u = objA;
            this.f6792v = 2;
        }
        return n.f457a;
    }
}
