package com.bumptech.glide.load;

import com.bumptech.glide.load.ImageHeaderParser;
import com.bumptech.glide.load.g;
import java.io.IOException;
import java.io.InputStream;

/* JADX INFO: loaded from: classes.dex */
class a implements g.b {
    public final /* synthetic */ InputStream a;

    public a(InputStream inputStream) {
        this.a = inputStream;
    }

    @Override // com.bumptech.glide.load.g.b
    public final ImageHeaderParser.ImageType a(ImageHeaderParser imageHeaderParser) throws IOException {
        InputStream inputStream = this.a;
        try {
            return imageHeaderParser.c(inputStream);
        } finally {
            inputStream.reset();
        }
    }
}
