After the full file has been read, the file position equals the number
of available bytes. The eof callback did not report EOF in this case.
static int meta_eof_cb(FLAC__IOHandle handle)
{
struct private_flac_afh_data *pfad = handle;
static int meta_eof_cb(FLAC__IOHandle handle)
{
struct private_flac_afh_data *pfad = handle;
- return pfad->fpos == pfad->map_bytes - 1;
+ return pfad->fpos == pfad->map_bytes;
}
static int meta_close_cb(FLAC__IOHandle __a_unused handle)
}
static int meta_close_cb(FLAC__IOHandle __a_unused handle)