From: Keith Whitwell Date: Mon, 29 Jun 2009 15:07:14 +0000 (+0100) Subject: progs/util: make sure function pointers are initialized X-Git-Tag: 062012170305~16521^2~181 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=14a2b5445a653e9a8258873300df8f04ac099e60;p=profile%2Fivi%2Fmesa.git progs/util: make sure function pointers are initialized Call Init() from CompileShaderFile, was previously only called for the Text version of this function. --- diff --git a/progs/util/shaderutil.c b/progs/util/shaderutil.c index 2f1c4e3..5cef84e 100644 --- a/progs/util/shaderutil.c +++ b/progs/util/shaderutil.c @@ -9,6 +9,7 @@ #include #include #include +#include #include #include "extfuncs.h" #include "shaderutil.h" @@ -78,8 +79,12 @@ CompileShaderFile(GLenum shaderType, const char *filename) int n; char *buffer = (char*) malloc(max); GLuint shader; + FILE *f; - FILE *f = fopen(filename, "r"); + Init(); + + + f = fopen(filename, "r"); if (!f) { fprintf(stderr, "Unable to open shader file %s\n", filename); return 0;