aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Niedermayer2008-03-06 00:20:49 +0000
committerMichael Niedermayer2008-03-06 00:20:49 +0000
commit16428e634824f27f6079efe378a09d66c9d4561e (patch)
tree164def46c3660a1bbcd7b36857b5396fc4a44522
parent9822564d1d66d9202bfec3fa78a93243963768dc (diff)
simplify
Originally committed as revision 12346 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r--libavformat/asf.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libavformat/asf.c b/libavformat/asf.c
index 30330c535a..638a42b6d8 100644
--- a/libavformat/asf.c
+++ b/libavformat/asf.c
@@ -389,7 +389,7 @@ static int asf_read_header(AVFormatContext *s, AVFormatParameters *ap)
get_str16_nolen(pb, name_len, name, sizeof(name));
value_type = get_le16(pb);
value_len = get_le16(pb);
- if ((value_type == 0) || (value_type == 1)) // unicode or byte
+ if (value_type <= 1) // unicode or byte
{
if (!strcmp(name,"WM/AlbumTitle")) get_str16_nolen(pb, value_len, s->album, sizeof(s->album));
else if(!strcmp(name,"WM/Genre" )) get_str16_nolen(pb, value_len, s->genre, sizeof(s->genre));
@@ -410,7 +410,7 @@ static int asf_read_header(AVFormatContext *s, AVFormatParameters *ap)
}
else url_fskip(pb, value_len);
}
- if ((value_type >= 2) && (value_type <= 5)) // boolean or DWORD or QWORD or WORD
+ else if (value_type <= 5) // boolean or DWORD or QWORD or WORD
{
value_num= get_value(pb, value_type);
if (!strcmp(name,"WM/Track" ) && s->track == 0) s->track = value_num + 1;