projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
952d0f8
)
mesa: Don't null deref looking for Mesa IR code at compile time.
author
Eric Anholt
<eric@anholt.net>
Wed, 4 Aug 2010 21:13:08 +0000
(14:13 -0700)
committer
Eric Anholt
<eric@anholt.net>
Wed, 4 Aug 2010 21:13:08 +0000
(14:13 -0700)
The new compiler doesn't generate Mesa IR at compile time, and that
compile time code previously wouldn't have reflected the link time
code that actually got used. But do dump the info log of the compile
regardless.
src/mesa/program/prog_print.c
patch
|
blob
|
history
diff --git
a/src/mesa/program/prog_print.c
b/src/mesa/program/prog_print.c
index 6ab199aa02bcddc4eea79a854866952283d4dce8..b66d709d50fece29f7bca79fd915fca6f70c23ed 100644
(file)
--- a/
src/mesa/program/prog_print.c
+++ b/
src/mesa/program/prog_print.c
@@
-1031,11
+1031,9
@@
_mesa_write_shader_to_file(const struct gl_shader *shader)
fprintf(f, "/* Compile status: %s */\n",
shader->CompileStatus ? "ok" : "fail");
- if (!shader->CompileStatus) {
- fprintf(f, "/* Log Info: */\n");
- fputs(shader->InfoLog, f);
- }
- else {
+ fprintf(f, "/* Log Info: */\n");
+ fputs(shader->InfoLog, f);
+ if (shader->CompileStatus && shader->Program) {
fprintf(f, "/* GPU code */\n");
fprintf(f, "/*\n");
_mesa_fprint_program_opt(f, shader->Program, PROG_PRINT_DEBUG, GL_TRUE);