mirror of
https://github.com/Shpoike/Quakespasm.git
synced 2024-11-10 07:21:58 +00:00
snd_mp3.c: return type tweak for mp3_tagsize()
git-svn-id: svn+ssh://svn.code.sf.net/p/quakespasm/code/trunk@1235 af15c1b1-3010-417e-b628-4374ebc0bcbd
This commit is contained in:
parent
e0fc971a95
commit
f7877d59f9
1 changed files with 5 additions and 5 deletions
|
@ -8,7 +8,7 @@
|
|||
* functions were adapted from the GPL-licensed libid3tag library, see at
|
||||
* http://www.underbit.com/products/mad/. Adapted to Quake and Hexen II
|
||||
* game engines by O.Sezer :
|
||||
* Copyright (C) 2010-2013 O.Sezer <sezero@users.sourceforge.net>
|
||||
* Copyright (C) 2010-2015 O.Sezer <sezero@users.sourceforge.net>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
@ -89,16 +89,16 @@ static inline qboolean tag_is_id3v2(const unsigned char *data, size_t length)
|
|||
return false;
|
||||
}
|
||||
|
||||
static int mp3_tagsize(const unsigned char *data, size_t length)
|
||||
static size_t mp3_tagsize(const unsigned char *data, size_t length)
|
||||
{
|
||||
size_t size;
|
||||
|
||||
if (tag_is_id3v1(data, length))
|
||||
return 128;
|
||||
|
||||
if (tag_is_id3v2(data, length))
|
||||
{
|
||||
unsigned char flags;
|
||||
unsigned int size;
|
||||
flags = data[5];
|
||||
unsigned char flags = data[5];
|
||||
size = 10 + (data[6]<<21) + (data[7]<<14) + (data[8]<<7) + data[9];
|
||||
if (flags & ID3_TAG_FLAG_FOOTERPRESENT)
|
||||
size += 10;
|
||||
|
|
Loading…
Reference in a new issue