summaryrefslogtreecommitdiffstats
path: root/apps/metadata/metadata_common.c
diff options
context:
space:
mode:
Diffstat (limited to 'apps/metadata/metadata_common.c')
-rw-r--r--apps/metadata/metadata_common.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/apps/metadata/metadata_common.c b/apps/metadata/metadata_common.c
index e1ef9a0d62..4f001775f3 100644
--- a/apps/metadata/metadata_common.c
+++ b/apps/metadata/metadata_common.c
@@ -337,7 +337,10 @@ long parse_tag(const char* name, char* value, struct mp3entry* id3,
p = NULL;
}
- if (p)
+ /* Do not overwrite already available metadata. Especially when reading
+ * tags with e.g. multiple genres / artists. This way only the first
+ * of multiple entries is used, all following are dropped. */
+ if (p!=NULL && *p==NULL)
{
len = strlen(value);
len = MIN(len, buf_remaining - 1);