use memcpy for isCurrentAudioFormat()
git-svn-id: https://svn.musicpd.org/mpd/trunk@969 09075e82-0dd4-0310-85a5-a0d7c8717e4f
This commit is contained in:
parent
2ec1c5ff3c
commit
9dd098f09b
|
@ -210,12 +210,7 @@ int isCurrentAudioFormat(AudioFormat * audioFormat) {
|
|||
#ifdef HAVE_AUDIO
|
||||
if(!audio_device || !audioFormat) return 0;
|
||||
|
||||
if(audio_format.bits!=audioFormat->bits ||
|
||||
audio_format.sampleRate!=audioFormat->sampleRate ||
|
||||
audio_format.channels!=audioFormat->channels)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
if(memcmp(audioFormat,&audio_format,sizeof(AudioFormat)) != 0) return 0;
|
||||
#endif
|
||||
return 1;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue