mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-11-10 16:09:09 +00:00
Handle 0-length strings correctly when doing reflection emulation
This commit is contained in:
1 file changed
+1
-1
@@ -437,7 +437,7 @@ void WrappedOpenGL::glShaderSource(GLuint shader, GLsizei count, const GLchar *c
|
||||
m_Shaders[id].sources.reserve(count);
|
||||
|
||||
for(GLsizei i = 0; i < count; i++)
|
||||
m_Shaders[id].sources.push_back((length && length[i] > 0)
|
||||
m_Shaders[id].sources.push_back((length && length[i] >= 0)
|
||||
? std::string(string[i], string[i] + length[i])
|
||||
: std::string(string[i]));
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user