Fix AudioReader::getInstrument under libsndfile

This commit is contained in:
Jean Pierre Cimalando 2020-11-04 08:55:34 +01:00
parent cda079eef8
commit 0bcf626786

View file

@ -53,7 +53,8 @@ bool BasicSndfileReader::getInstrument(InstrumentInfo* instrument)
{
#if defined(SFIZZ_USE_SNDFILE)
SNDFILE* sndfile = reinterpret_cast<SNDFILE*>(handle_.get_sndfile_handle());
if (sf_command(sndfile, SFC_GET_INSTRUMENT, &instrument, sizeof(instrument)) == SF_TRUE)
SF_INSTRUMENT* sfins = instrument;
if (sf_command(sndfile, SFC_GET_INSTRUMENT, sfins, sizeof(SF_INSTRUMENT)) == SF_TRUE)
return true;
#else
(void)instrument;