diff options
| author | Ray <[email protected]> | 2024-01-13 16:57:25 +0100 |
|---|---|---|
| committer | Ray <[email protected]> | 2024-01-13 16:57:25 +0100 |
| commit | cb2572fe07ea49b951198a0adc189a8e903244ca (patch) | |
| tree | cea7ff24f9b114953b2b4926389b943f37c8710d /src | |
| parent | 520c8cffb2f1b5e7d5574e6be6e502489e75ff55 (diff) | |
| download | raylib-cb2572fe07ea49b951198a0adc189a8e903244ca.tar.gz raylib-cb2572fe07ea49b951198a0adc189a8e903244ca.zip | |
Avoid asserts because could crash some decompressions https://github.com/raysan5/raygui/issues/364
Diffstat (limited to 'src')
| -rw-r--r-- | src/external/sinfl.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/external/sinfl.h b/src/external/sinfl.h index 16589c17..1f6bf6f0 100644 --- a/src/external/sinfl.h +++ b/src/external/sinfl.h @@ -231,13 +231,13 @@ sinfl_refill(struct sinfl *s) { } static int sinfl_peek(struct sinfl *s, int cnt) { - assert(cnt >= 0 && cnt <= 56); - assert(cnt <= s->bitcnt); + //assert(cnt >= 0 && cnt <= 56); // @raysan5: commented to avoid crash on decompression + //assert(cnt <= s->bitcnt); return s->bitbuf & ((1ull << cnt) - 1); } static void sinfl_eat(struct sinfl *s, int cnt) { - assert(cnt <= s->bitcnt); + //assert(cnt <= s->bitcnt); // @raysan5: commented s->bitbuf >>= cnt; s->bitcnt -= cnt; } |
