Pārlūkot izejas kodu

Delete shader in case compilation fails

pull/5005/head
Ray pirms 3 mēnešiem
vecāks
revīzija
b677376088
1 mainītis faili ar 3 papildinājumiem un 0 dzēšanām
  1. +3
    -0
      src/rlgl.h

+ 3
- 0
src/rlgl.h Parādīt failu

@ -4178,6 +4178,9 @@ unsigned int rlCompileShader(const char *shaderCode, int type)
RL_FREE(log);
}
// Unload object allocated by glCreateShader(),
// despite failing in the compilation process
glDeleteShader(shader);
shader = 0;
}
else

Notiek ielāde…
Atcelt
Saglabāt