package a.c.b;

import java.nio.ByteBuffer;

public class g {

    /* renamed from: a  reason: collision with root package name */
    public static final byte[] f73a;
    public static final ByteBuffer b;
    private static final int c = 131072;
    private static final ThreadLocal<byte[]> d = ThreadLocal.withInitial($$Lambda$g$J4X07UqnvRKl_UTdwpH044s0anw.INSTANCE);
    private static final ThreadLocal<ByteBuffer> e = ThreadLocal.withInitial($$Lambda$g$qtMtmhG1osbjAbiLR5T9BqqEWE.INSTANCE);

    static {
        byte[] bArr = new byte[0];
        f73a = bArr;
        b = ByteBuffer.wrap(bArr);
    }

    /* access modifiers changed from: private */
    public static /* synthetic */ byte[] a() {
        return new byte[131072];
    }

    public static byte[] a(int i) {
        return i <= 131072 ? d.get() : new byte[i];
    }

    /* access modifiers changed from: private */
    public static /* synthetic */ ByteBuffer b() {
        return ByteBuffer.wrap(a(131072));
    }

    public static ByteBuffer b(int i) {
        ByteBuffer allocate = i <= 131072 ? e.get() : ByteBuffer.allocate(i);
        if (allocate != null) {
            allocate.clear();
            allocate.limit(i);
        }
        return allocate;
    }
}
