summaryrefslogtreecommitdiff
path: root/apps/metadata/id3tags.c
diff options
context:
space:
mode:
Diffstat (limited to 'apps/metadata/id3tags.c')
-rw-r--r--apps/metadata/id3tags.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/apps/metadata/id3tags.c b/apps/metadata/id3tags.c
index 9143f8ad25..9ee183a1b3 100644
--- a/apps/metadata/id3tags.c
+++ b/apps/metadata/id3tags.c
@@ -358,7 +358,8 @@ static int parseuser( struct mp3entry* entry, char* tag, int bufferpos )
358 358
359 if ((tag - entry->id3v2buf + desc_len + 2) < bufferpos) { 359 if ((tag - entry->id3v2buf + desc_len + 2) < bufferpos) {
360 /* At least part of the value was read, so we can safely try to 360 /* At least part of the value was read, so we can safely try to
361 * parse it */ 361 * parse it
362 */
362 value = tag + desc_len + 1; 363 value = tag + desc_len + 1;
363 value_len = bufferpos - (tag - entry->id3v2buf); 364 value_len = bufferpos - (tag - entry->id3v2buf);
364 365
@@ -367,7 +368,8 @@ static int parseuser( struct mp3entry* entry, char* tag, int bufferpos )
367 entry->albumartist = tag; 368 entry->albumartist = tag;
368#if CONFIG_CODEC == SWCODEC 369#if CONFIG_CODEC == SWCODEC
369 } else { 370 } else {
370 value_len = parse_replaygain(tag, value, entry, tag, value_len); 371 value_len = parse_replaygain(tag, value, entry, tag,
372 value_len);
371#endif 373#endif
372 } 374 }
373 } 375 }
@@ -1038,12 +1040,6 @@ void setid3v2title(int fd, struct mp3entry *entry)
1038#endif 1040#endif
1039 if( tr->ppFunc ) 1041 if( tr->ppFunc )
1040 bufferpos = tr->ppFunc(entry, tag, bufferpos); 1042 bufferpos = tr->ppFunc(entry, tag, bufferpos);
1041
1042 /* Trim. Take into account that multiple string contents will
1043 * only be displayed up to their first null termination. All
1044 * content after this null termination is obsolete and can be
1045 * overwritten. */
1046 bufferpos -= (bytesread - strlen(tag));
1047 1043
1048 /* Seek to the next frame */ 1044 /* Seek to the next frame */
1049 if(framelen < totframelen) 1045 if(framelen < totframelen)