removed redundant size checks

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@2298 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Daniel Stenberg 2002-09-16 10:42:27 +00:00
parent f9a46c1cda
commit a6df1fd48d

View file

@ -234,8 +234,6 @@ static void setid3v2title(int fd, struct mp3entry *entry)
!strncmp(header, "TP1", strlen("TP1"))) {
readsize++;
headerlen--;
if(headerlen > (size - readsize))
headerlen = (size - readsize);
artist = buffer + readsize;
artistn = headerlen;
readsize += headerlen;
@ -244,8 +242,6 @@ static void setid3v2title(int fd, struct mp3entry *entry)
!strncmp(header, "TT2", strlen("TT2"))) {
readsize++;
headerlen--;
if(headerlen > (size - readsize))
headerlen = (size - readsize);
title = buffer + readsize;
titlen = headerlen;
readsize += headerlen;
@ -253,8 +249,6 @@ static void setid3v2title(int fd, struct mp3entry *entry)
else if(!strncmp(header, "TALB", strlen("TALB"))) {
readsize++;
headerlen--;
if(headerlen > (size - readsize))
headerlen = (size - readsize);
album = buffer + readsize;
albumn = headerlen;
readsize += headerlen;
@ -262,8 +256,6 @@ static void setid3v2title(int fd, struct mp3entry *entry)
else if(!strncmp(header, "TRCK", strlen("TRCK"))) {
readsize++;
headerlen--;
if(headerlen > (size - readsize))
headerlen = (size - readsize);
tracknum = buffer + readsize;
tracknumn = headerlen;
readsize += headerlen;