2
0
Эх сурвалжийг харах

shaderpipeline: Fix crash in glslang front-end

rdb 5 жил өмнө
parent
commit
e7920aeb91

+ 1 - 1
panda/src/shaderpipeline/shaderCompilerGlslang.cxx

@@ -461,7 +461,7 @@ bool ShaderCompilerGlslang::
 check_cg_header(const vector_uchar &code) {
   const char *p = (const char *)&code[0];
   const char *end = p + code.size();
-  while (isspace(*p) && p < end) {
+  while (p < end && isspace(*p)) {
     // Skip leading whitespace.
     ++p;
   }