Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClément Foucault <foucault.clem@gmail.com>2022-02-09 01:15:52 +0300
committerClément Foucault <foucault.clem@gmail.com>2022-03-18 22:49:22 +0300
commit4544761a2d5cc5dfc42f5e374a9ec67144d4dd40 (patch)
tree94efc2b24c2ca5dde149769794ef89f5b101e57e /source/blender/gpu/intern/gpu_shader_log.cc
parent59f53f5802276c4ff1d8e5422a76e54f94383626 (diff)
GPUShader: Fix crash when compilation error is a linking error
Diffstat (limited to 'source/blender/gpu/intern/gpu_shader_log.cc')
-rw-r--r--source/blender/gpu/intern/gpu_shader_log.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/gpu/intern/gpu_shader_log.cc b/source/blender/gpu/intern/gpu_shader_log.cc
index d67dd56b45b..83fc34a3278 100644
--- a/source/blender/gpu/intern/gpu_shader_log.cc
+++ b/source/blender/gpu/intern/gpu_shader_log.cc
@@ -78,6 +78,9 @@ void Shader::print_log(Span<const char *> sources,
}
#endif
}
+ if (sources_end_line.size() == 0) {
+ sources_end_line.append(0);
+ }
char *log_line = log, *line_end;