summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--firmware/mp3data.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/firmware/mp3data.c b/firmware/mp3data.c
index 83d916ff9f..896ecda7f0 100644
--- a/firmware/mp3data.c
+++ b/firmware/mp3data.c
@@ -634,13 +634,11 @@ int create_xing_header(int fd, int startpos, int filesize,
634 filepos += info.frame_size; 634 filepos += info.frame_size;
635 } 635 }
636 636
637 /* Save a header for later use. Yes, we may be passed a header 637 /* Save a header for later use if header_template is empty.
638 template in the header_template argument, but since we are 638 We only save one header, and we want to save one in the
639 reading headers from the stream anyway, we might as well 639 middle of the stream, just in case the first and the last
640 use the ones we find. However, we only save one header, and 640 headers are corrupt. */
641 we want to save one in te middle of the stream, just in case 641 if(!header_template && i == 1)
642 the first and the last headers are corrupt. */
643 if(i == 1)
644 header_template = header; 642 header_template = header;
645 643
646 if(progressfunc) 644 if(progressfunc)