diff options
| author | trialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38> | 2016-07-26 06:57:29 +0000 |
|---|---|---|
| committer | trialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38> | 2016-07-26 06:57:29 +0000 |
| commit | 411581182475289ad1ec80dac8d41d71c2eefb38 (patch) | |
| tree | ae4e711400a5c7e139cecc617ea01c0f25f2b31c /src | |
| parent | d1ead55da26e5bbe044c9dcc9c5420a2339132e8 (diff) | |
| download | qmmp-411581182475289ad1ec80dac8d41d71c2eefb38.tar.gz qmmp-411581182475289ad1ec80dac8d41d71c2eefb38.tar.bz2 qmmp-411581182475289ad1ec80dac8d41d71c2eefb38.zip | |
optimization in the DecoderMADFactory::canDecode function
git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@6600 90c681e8-e032-0410-971d-27865f9a5e38
Diffstat (limited to 'src')
| -rw-r--r-- | src/plugins/Input/mad/decodermadfactory.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/plugins/Input/mad/decodermadfactory.cpp b/src/plugins/Input/mad/decodermadfactory.cpp index b4e957b0e..a14eb17ea 100644 --- a/src/plugins/Input/mad/decodermadfactory.cpp +++ b/src/plugins/Input/mad/decodermadfactory.cpp @@ -84,6 +84,9 @@ bool DecoderMADFactory::canDecode(QIODevice *input) const if (input->peek(buf,sizeof(buf)) == sizeof(buf)) { + if (!memcmp(buf + 8, "WAVE", 4) && !memcmp(buf + 20, "U" ,1)) + return true; + struct mad_stream stream; struct mad_header header; int dec_res; |
