Fix Buffer Overflow#640
Conversation
Update GetInt functions to use array for results with a fixed size of 4
|
Sorry about earlier, I had some problems with branches and ended up making a mess; git is still quite confusing for me. |
|
From what I've researched, some values within OpenGL use arrays of 4 integers, such as viewports, colors, positions, etc... |
adriengivry
left a comment
There was a problem hiding this comment.
Looks good to me. I believe this solution is satisfactory for now. In the future we'll have to look into alternative solutions to avoid allocating unnecessary memory and protect other getters (float, bool, int64...) from buffer overruns.
Thanks for your contribution!
|
thank you and all the best! |
Update GetInt functions to use array for results with a fixed size of 4
Description
Fix for Buffer Overflow by limiting the number of integers in GLint:
Related Issue(s)
Fixes #634
Checklist
See also
Why a fixed value of 4?