struct FileTypeDetectionBuffer *detect = &input_ctx->detect;
int plane = 0;
int shortread = 0;
- const int bytespp = (input_ctx->fmt & VPX_IMG_FMT_HIGH) ? 2 : 1;
+ const int bytespp = (yuv_frame->fmt & VPX_IMG_FMT_HIGH) ? 2 : 1;
for (plane = 0; plane < 3; ++plane) {
uint8_t *ptr;
int y;
for (y = 0; y < h; ++y) {
- if (fread(buf, 1, w, file) != w)
+ if (fread(buf, 1, w, file) != (size_t)w)
return 0;
buf += stride;
}