diff options
author | J. Alexander Treuman <jat@spatialrift.net> | 2006-08-07 17:53:53 +0000 |
---|---|---|
committer | J. Alexander Treuman <jat@spatialrift.net> | 2006-08-07 17:53:53 +0000 |
commit | 8e8fd7f1d7b486281db76c6d48e94a9c3f9e3cf4 (patch) | |
tree | f73d777048c7b85903755efa2a45b5889a0f6dac | |
parent | ff0a2543a60def86d44e789fdc9a50c2bda25788 (diff) | |
download | mpd-8e8fd7f1d7b486281db76c6d48e94a9c3f9e3cf4.tar.gz mpd-8e8fd7f1d7b486281db76c6d48e94a9c3f9e3cf4.tar.xz mpd-8e8fd7f1d7b486281db76c6d48e94a9c3f9e3cf4.zip |
Use memcmp to compare audio formats
git-svn-id: https://svn.musicpd.org/mpd/trunk@4585 09075e82-0dd4-0310-85a5-a0d7c8717e4f
-rw-r--r-- | src/audio.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/audio.c b/src/audio.c index d17679969..203c37246 100644 --- a/src/audio.c +++ b/src/audio.c @@ -84,8 +84,7 @@ void copyAudioFormat(AudioFormat * dest, AudioFormat * src) int cmpAudioFormat(AudioFormat * f1, AudioFormat * f2) { - if (f1 && f2 && (f1->sampleRate == f2->sampleRate) && - (f1->bits == f2->bits) && (f1->channels == f2->channels)) + if (f1 && f2 && (0 == memcmp(f1, f2, sizeof(AudioFormat)))) return 0; return 1; } |