mirror of
https://github.com/nothings/stb
synced 2025-01-18 20:29:20 +03:00
attempt to fix unused var warnings in stb_image 2.09
This commit is contained in:
parent
f1d2002a1d
commit
30015ef464
@ -1,4 +1,4 @@
|
||||
/* stb_image - v2.09 - public domain image loader - http://nothings.org/stb_image.h
|
||||
/* stb_image - v2.10 - public domain image loader - http://nothings.org/stb_image.h
|
||||
no warranty implied; use at your own risk
|
||||
|
||||
Do this:
|
||||
@ -146,6 +146,7 @@
|
||||
|
||||
|
||||
Latest revision history:
|
||||
2.10 (2016-01-22) avoid warning introduced in 2.09
|
||||
2.09 (2016-01-16) 16-bit TGA; comments in PNM files; STBI_REALLOC_SIZED
|
||||
2.08 (2015-09-13) fix to 2.07 cleanup, reading RGB PSD as RGBA
|
||||
2.07 (2015-09-13) partial animated GIF support
|
||||
@ -3621,6 +3622,7 @@ static int stbi__zexpand(stbi__zbuf *z, char *zout, int n) // need to make room
|
||||
while (cur + n > limit)
|
||||
limit *= 2;
|
||||
q = (char *) STBI_REALLOC_SIZED(z->zout_start, old_limit, limit);
|
||||
STBI_NOTUSED(old_limit);
|
||||
if (q == NULL) return stbi__err("outofmem", "Out of memory");
|
||||
z->zout_start = q;
|
||||
z->zout = q + cur;
|
||||
@ -4410,6 +4412,7 @@ static int stbi__parse_png_file(stbi__png *z, int scan, int req_comp)
|
||||
if (idata_limit == 0) idata_limit = c.length > 4096 ? c.length : 4096;
|
||||
while (ioff + c.length > idata_limit)
|
||||
idata_limit *= 2;
|
||||
STBI_NOTUSED(idata_limit_old);
|
||||
p = (stbi_uc *) STBI_REALLOC_SIZED(z->idata, idata_limit_old, idata_limit); if (p == NULL) return stbi__err("outofmem", "Out of memory");
|
||||
z->idata = p;
|
||||
}
|
||||
@ -6456,6 +6459,7 @@ STBIDEF int stbi_info_from_callbacks(stbi_io_callbacks const *c, void *user, int
|
||||
|
||||
/*
|
||||
revision history:
|
||||
2.10 (2016-01-22) avoid warning introduced in 2.09 by STBI_REALLOC_SIZED
|
||||
2.09 (2016-01-16) allow comments in PNM files
|
||||
16-bit-per-pixel TGA (not bit-per-component)
|
||||
info() for TGA could break due to .hdr handling
|
||||
|
Loading…
Reference in New Issue
Block a user