package o; import java.util.ArrayDeque; /* renamed from: o.fXo, reason: case insensitive filesystem */ /* loaded from: classes6.dex */ public final class C13341fXo extends fUX { private int a; public C13341fXo(InterfaceC13169fSq interfaceC13169fSq, int i) { super(interfaceC13169fSq); this.a = i; } @Override // o.AbstractC13163fSk public final void subscribeActual(InterfaceC13174fSv interfaceC13174fSv) { this.c.subscribe(new RVV(interfaceC13174fSv, this.a)); } /* renamed from: o.fXo$RVV */ /* loaded from: classes6.dex */ static final class RVV extends ArrayDeque implements InterfaceC13174fSv, fSJ { private InterfaceC13174fSv a; private int b; private fSJ d; RVV(InterfaceC13174fSv interfaceC13174fSv, int i) { super(i); this.a = interfaceC13174fSv; this.b = i; } @Override // o.InterfaceC13174fSv public final void onSubscribe(fSJ fsj) { if (EnumC13192fTf.d(this.d, fsj)) { this.d = fsj; this.a.onSubscribe(this); } } @Override // o.fSJ public final void dispose() { this.d.dispose(); } @Override // o.fSJ public final boolean isDisposed() { return this.d.isDisposed(); } @Override // o.InterfaceC13174fSv public final void onNext(T t) { if (this.b == size()) { this.a.onNext(poll()); } offer(t); } @Override // o.InterfaceC13174fSv public final void onError(Throwable th) { this.a.onError(th); } @Override // o.InterfaceC13174fSv public final void onComplete() { this.a.onComplete(); } } }