package o;

/* compiled from: r8-map-id-3b7cc9102578c509342fa2f0fabed2bfc72239cd258d579fc679bfcbc198b048 */
/* renamed from: o.Bs, reason: case insensitive filesystem */
/* loaded from: classes.dex */
public final class C0044Bs implements CZ {
    public static final Object n = new Object();
    public volatile InterfaceC3051yx l;
    public volatile Object m;

    public static CZ a(InterfaceC3051yx interfaceC3051yx) {
        if (interfaceC3051yx instanceof C0044Bs) {
            return interfaceC3051yx;
        }
        C0044Bs c0044Bs = new C0044Bs();
        c0044Bs.m = n;
        c0044Bs.l = interfaceC3051yx;
        return c0044Bs;
    }

    @Override // o.CZ
    public final Object get() {
        Object obj;
        Object obj2 = this.m;
        Object obj3 = n;
        if (obj2 != obj3) {
            return obj2;
        }
        synchronized (this) {
            try {
                obj = this.m;
                if (obj == obj3) {
                    obj = this.l.get();
                    Object obj4 = this.m;
                    if (obj4 != obj3 && obj4 != obj) {
                        throw new IllegalStateException("Scoped provider was invoked recursively returning different results: " + obj4 + " & " + obj + ". This is likely due to a circular dependency.");
                    }
                    this.m = obj;
                    this.l = null;
                }
            } catch (Throwable th) {
                throw th;
            }
        }
        return obj;
    }
}
