projects
/
taglib
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e178875
)
Skip both ID3v1 and APE tags when seeking the last MPEG frame.
author
Tsuda Kageyu
<tsuda.kageyu@gmail.com>
Wed, 27 May 2015 01:04:52 +0000
(10:04 +0900)
committer
Tsuda Kageyu
<tsuda.kageyu@gmail.com>
Fri, 28 Aug 2015 08:04:15 +0000
(17:04 +0900)
taglib/mpeg/mpegfile.cpp
patch
|
blob
|
history
diff --git
a/taglib/mpeg/mpegfile.cpp
b/taglib/mpeg/mpegfile.cpp
index 43075cfc091528eebde9ee374ef015ba987ced28..9ae1dffaba4574697cb7d0425530436ebecbdb06 100644
(file)
--- a/
taglib/mpeg/mpegfile.cpp
+++ b/
taglib/mpeg/mpegfile.cpp
@@
-469,7
+469,16
@@
long MPEG::File::firstFrameOffset()
long MPEG::File::lastFrameOffset()
{
- return previousFrameOffset(hasID3v1Tag() ? d->ID3v1Location - 1 : length());
+ long position;
+
+ if(hasAPETag())
+ position = d->APELocation - 1;
+ else if(hasID3v1Tag())
+ position = d->ID3v1Location - 1;
+ else
+ position = length();
+
+ return previousFrameOffset(position);
}
bool MPEG::File::hasID3v1Tag() const