package o; import io.reactivex.rxjava3.exceptions.CompositeException; import java.util.concurrent.atomic.AtomicReference; /* renamed from: o.fTy, reason: case insensitive filesystem */ /* loaded from: classes6.dex */ abstract class AbstractC13211fTy extends AtomicReference implements fSJ { private AtomicReference a; private fSP c; private fSQ e; /* JADX INFO: Access modifiers changed from: package-private */ public AbstractC13211fTy(InterfaceC13145fSF interfaceC13145fSF, fSQ fsq, fSP fsp) { this.e = fsq; this.c = fsp; this.a = new AtomicReference<>(interfaceC13145fSF); } public final void onError(Throwable th) { if (get() != EnumC13192fTf.DISPOSED) { lazySet(EnumC13192fTf.DISPOSED); try { this.e.c(th); } catch (Throwable th2) { C13147fSI.c(th2); C13418fZu.c(new CompositeException(th, th2)); } } else { C13418fZu.c(th); } InterfaceC13145fSF andSet = this.a.getAndSet(null); if (andSet != null) { andSet.b(this); } } public final void onComplete() { if (get() != EnumC13192fTf.DISPOSED) { lazySet(EnumC13192fTf.DISPOSED); try { this.c.c(); } catch (Throwable th) { C13147fSI.c(th); C13418fZu.c(th); } } InterfaceC13145fSF andSet = this.a.getAndSet(null); if (andSet != null) { andSet.b(this); } } @Override // o.fSJ public final void dispose() { EnumC13192fTf.e(this); InterfaceC13145fSF andSet = this.a.getAndSet(null); if (andSet != null) { andSet.b(this); } } @Override // o.fSJ public final boolean isDisposed() { return EnumC13192fTf.c(get()); } public final void onSubscribe(fSJ fsj) { EnumC13192fTf.a(this, fsj); } }