forked from len0rd/rockbox
Fix FORMAT_RETURN_SIZE in read_bmp_*() when scaling (thanks to Andrew Mahone)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21078 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
7b16010838
commit
0bddb7eb65
1 changed files with 4 additions and 0 deletions
|
|
@ -597,7 +597,11 @@ int read_bmp_fd(int fd,
|
|||
totalsize = BM_SIZE(bm->width,bm->height,format,remote);
|
||||
|
||||
if(return_size)
|
||||
{
|
||||
if(resize)
|
||||
totalsize += BM_SCALED_SIZE(bm->width, 0, 0, 0);
|
||||
return totalsize;
|
||||
}
|
||||
|
||||
/* Check if this fits the buffer */
|
||||
if (totalsize > maxsize) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue