summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorJack Whitham <jack.d.whitham@gmail.com>2013-07-11 21:09:58 +0100
committerThomas Martitz <kugel@rockbox.org>2013-12-23 17:55:15 +0100
commitca423ed0e317645c8febb8dc604743f0fd47139a (patch)
tree4f8ab0164eb64558d0b8db8286ffb92655b4e993 /lib
parent10d71bb910d96aae5d0ac2e868c961d6b104c1bd (diff)
downloadrockbox-ca423ed0e317645c8febb8dc604743f0fd47139a.tar.gz
rockbox-ca423ed0e317645c8febb8dc604743f0fd47139a.tar.bz2
rockbox-ca423ed0e317645c8febb8dc604743f0fd47139a.zip
Proposed fix for FS#12878: Zero-length embedded album art prevents mp3 playback
see http://www.rockbox.org/tracker/task/12878 Change-Id: Ib4233c06e18d1d193dfb9e73e745ca5d174e40b2 Reviewed-on: http://gerrit.rockbox.org/507 Reviewed-by: Michael Giacomelli <giac2000@hotmail.com> Reviewed-by: Thomas Martitz <kugel@rockbox.org>
Diffstat (limited to 'lib')
-rw-r--r--lib/rbcodec/metadata/id3tags.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/rbcodec/metadata/id3tags.c b/lib/rbcodec/metadata/id3tags.c
index fed99d81a0..3492197c40 100644
--- a/lib/rbcodec/metadata/id3tags.c
+++ b/lib/rbcodec/metadata/id3tags.c
@@ -355,7 +355,8 @@ static int parsealbumart( struct mp3entry* entry, char* tag, int bufferpos )
/* fixup offset&size for image data */
entry->albumart.pos += tag - start;
entry->albumart.size -= tag - start;
- entry->has_embedded_albumart = true;
+ /* check for malformed tag with no picture data */
+ entry->has_embedded_albumart = (entry->albumart.size != 0);
}
/* return bufferpos as we didn't store anything in id3v2buf */
return bufferpos;