- 19 3月, 2017 6 次提交
-
-
由 Sean Barrett 提交于
-
https://github.com/nothings/stb/pull/427由 Sean Barrett 提交于
so you don't get the automatic info you normally do
-
由 Sean Barrett 提交于
-
由 Sean Barrett 提交于
-
由 Sean Barrett 提交于
-
由 Sean Barrett 提交于
-
- 05 3月, 2017 2 次提交
-
-
由 Fabian Giesen 提交于
My guideline for the rules is the PNG loader (which I consider "canonical"). In the _load functions, x and y are required but comp is optional; in the _info functions, all three are optional. Fixes issue #411 (and other related, unreported issues).
-
由 Fabian Giesen 提交于
We tried but it was nothing but trouble. New rule: with GCC/Clang, if you're compiling with -msse2, you get always-on SSE2 code, otherwise you don't get any. Trying to ship anything with proper runtime dispatch requires both working around certain bugs and some fiddling with build settings, which runs contrary to the intent of a one-file library, so bail on it entirely. Fixes issue #280. Fixes issue #410.
-
- 04 3月, 2017 6 次提交
-
-
由 Jeremy Sawicki 提交于
-
-
由 Sean Barrett 提交于
-
由 Sean Barrett 提交于
-
由 Sean Barrett 提交于
-
由 Sean Barrett 提交于
tweak license reference wording
-
- 03 3月, 2017 9 次提交
-
-
由 Sean Barrett 提交于
-
由 Jeremy Sawicki 提交于
-
由 Jeremy Sawicki 提交于
-
由 Jeremy Sawicki 提交于
-
由 Jeremy Sawicki 提交于
-
由 Jeremy Sawicki 提交于
-
由 Jeremy Sawicki 提交于
-
由 Jeremy Sawicki 提交于
-
由 Jeremy Sawicki 提交于
-
- 16 1月, 2017 4 次提交
-
-
由 themanagainstthetank 提交于
int raw_data[4] to 0, or the compiler bugs
-
由 Sean Barrett 提交于
-
由 Sean Barrett 提交于
-
由 Sean Barrett 提交于
-
- 28 12月, 2016 1 次提交
-
-
由 Thomas Ruf 提交于
more of "allocate large structures on the stack", this time in the forgotten stbi__jpeg_test -> avoids the infamous _chkstk() when working with CRT
-
- 16 12月, 2016 1 次提交
-
-
由 sammyhw 提交于
-
- 04 12月, 2016 4 次提交
-
-
由 Sean Barrett 提交于
-
由 Sean Barrett 提交于
-
由 Sean Barrett 提交于
-
由 Sean Barrett 提交于
-
- 29 11月, 2016 4 次提交
-
-
由 Sean Barrett 提交于
-
由 Sean Barrett 提交于
-
由 jon 提交于
-
由 jon 提交于
-
- 22 10月, 2016 3 次提交
-
-
由 Fabian Giesen 提交于
stbi__process_frame_header had two bugs when dealing with progressive JPEGs: 1. when malloc failed allocating raw_data, previous components' raw_coeff didn't get freed 2. no out-of-memory check in raw_coeff allocation Fix both and share a bit more cleanup code in general.
-
由 Fabian Giesen 提交于
Runs need to be bounds checked. Fixes issues #315, #317.
-
由 Fabian Giesen 提交于
Adds some helpers that check whether a product of multiple factors (that need to be non-negative: this is enforced) summed with another non-negative value overflows when performed as int. Since stb_image mostly works in ints, this seems like the safest route. Limits size of images to 2GB but several of the decoders already enforce this limit (or even lower ones). Also adds wrappers for malloc that combine a mul-add-with- overflow-check with the actual malloc, and return NULL on failure. Then use them when allocating something that is the product of multiple factors. For image formats, also add a top-level "is this too big?" check that gives a more useful error message; otherwise, the failed mallocs result in an "out of memory" error. The idea is that the top-level checks should be the primary way to catch these bugs (and produce a useful error message). But a misleading error message is still vastly preferable to a buffer overflow exploit. Fixes issues #310, #313, #314, #318. (Verified with the provided test images) Along the way, this fixes a previously unnoticed bug in ldr_to_hdr / hdr_to_ldr (missing NULL check); these functions are called with the result of an image decoder, so NULLs can definitely happen. Another bug noticed along the way is that handling of interlaced 16-bit PNGs was incorrect. Fixing this (along with the previous modifications) fixes issue #311. Yet another bug noticed during this change is that reduce_png did not check the right pointer during its out of memory check. Fix that too.
-