Use a local variable in SDL_GL_ATTRIBUTES macro instead of relying on it being declared in the function calling the macro

git-svn-id: https://svn.eduke32.com/eduke32@7044 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
terminx 2018-10-07 05:23:39 +00:00
parent aa939642d6
commit 78a3797295

View file

@ -27,7 +27,7 @@ int32_t SDL_WaitEventTimeout(SDL_Event *event, int32_t timeout);
#define SDL_GL_ATTRIBUTES(iter, attrib) \ #define SDL_GL_ATTRIBUTES(iter, attrib) \
for (iter = 0; iter < (int32_t)ARRAY_SIZE(attrib); iter++) \ for (iter = 0; iter < (int32_t)ARRAY_SIZE(attrib); iter++) \
{ \ { \
j = attrib[iter].value; \ int32_t j = attrib[iter].value; \
if (!multisamplecheck && \ if (!multisamplecheck && \
(attrib[iter].attr == SDL_GL_MULTISAMPLEBUFFERS || attrib[iter].attr == SDL_GL_MULTISAMPLESAMPLES)) \ (attrib[iter].attr == SDL_GL_MULTISAMPLEBUFFERS || attrib[iter].attr == SDL_GL_MULTISAMPLESAMPLES)) \
{ \ { \