diff --git a/src/GLProgramLoader.cc b/src/GLProgramLoader.cc index 9d07654..84918f7 100644 --- a/src/GLProgramLoader.cc +++ b/src/GLProgramLoader.cc @@ -79,5 +79,9 @@ GLuint compile_and_link_program(const std::vector throw GLProgramException(std::format("Program {} link failed:\n{}", program_id, error_log)); } + for (auto &s:shader_ids) { + glDeleteShader(s); + } + return program_id; -} \ No newline at end of file +}