diff options
author | JayXon <jayxon@gmail.com> | 2019-11-11 11:22:20 +0300 |
---|---|---|
committer | JayXon <jayxon@gmail.com> | 2019-11-11 11:22:20 +0300 |
commit | fb5bb4c12e227e541f0e4dc3a0bf966a02b2ce36 (patch) | |
tree | 26353f8bfa8d54a82997bd779c6ef8722e058d74 /lodepng.cpp | |
parent | 46108887d2013c18ab221503f68e34df7caa6269 (diff) |
Fix alloc fail check.
Diffstat (limited to 'lodepng.cpp')
-rw-r--r-- | lodepng.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lodepng.cpp b/lodepng.cpp index 79d5baa..eeb16c6 100644 --- a/lodepng.cpp +++ b/lodepng.cpp @@ -2251,7 +2251,7 @@ unsigned lodepng_zlib_compress(unsigned char** out, size_t* outsize, const unsig if(!error) { *outsize = deflatesize + 6; *out = (unsigned char*)lodepng_malloc(*outsize); - if(!out) error = 83; /*alloc fail*/ + if(!*out) error = 83; /*alloc fail*/ } if(!error) { |