From 9053faa7cac1cf05a3659d1b5b24d456d96e4d22 Mon Sep 17 00:00:00 2001 From: Kyle K Date: Mon, 18 Jul 2011 14:42:56 -0500 Subject: sdl: make platform more generic by splitting some code into client struct --- sdl/gltools.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'sdl/gltools.c') diff --git a/sdl/gltools.c b/sdl/gltools.c index 2449cfc..7fc92f7 100644 --- a/sdl/gltools.c +++ b/sdl/gltools.c @@ -30,7 +30,10 @@ GLuint gltLoadTGATexture(const char *fname) pBytes = gltLoadTGA(fname, &iWidth, &iHeight, &iComponents, &eFormat); if (!pBytes) + { fprintf(stderr, "gltLoadTGA: failed to load texture!\n"); + return -1; + } glTexImage2D(GL_TEXTURE_2D, 0, iComponents, iWidth, iHeight, 0, eFormat, GL_UNSIGNED_BYTE, pBytes); -- cgit v1.2.3