summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJean-Philippe Andre <jp.andre@samsung.com>2017-03-08 15:51:02 +0900
committerJean-Philippe Andre <jp.andre@samsung.com>2017-03-08 15:51:02 +0900
commit8b9361e75c59b9e6bc44d9330798db40a02089b5 (patch)
tree1ec31fd567c881f3aa4024fc49fed5d23bebdea4
parent265c851a8f2ac3cd1f93d523736d4cce0454fe2c (diff)
tests: Don't print garbage
GLView tends to print some random garbage when using the GLView Gears test. That's because we're allocating and printing a 0 byte buffer. Don't do that.
-rw-r--r--src/bin/elementary/test_glview.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/bin/elementary/test_glview.c b/src/bin/elementary/test_glview.c
index beb291a693..1a3432ee63 100644
--- a/src/bin/elementary/test_glview.c
+++ b/src/bin/elementary/test_glview.c
@@ -350,6 +350,7 @@ _print_gl_log(Evas_GL_API *gl, GLuint id)
350 gl->glGetShaderiv(id, GL_INFO_LOG_LENGTH, &log_len); 350 gl->glGetShaderiv(id, GL_INFO_LOG_LENGTH, &log_len);
351 else if (gl->glIsProgram(id)) 351 else if (gl->glIsProgram(id))
352 gl->glGetProgramiv(id, GL_INFO_LOG_LENGTH, &log_len); 352 gl->glGetProgramiv(id, GL_INFO_LOG_LENGTH, &log_len);
353 if (!log_len) return;
353 354
354 log_info = malloc(log_len * sizeof(char)); 355 log_info = malloc(log_len * sizeof(char));
355 356
@@ -439,7 +440,8 @@ _del_gl(Evas_Object *obj)
439 GLData *gld = evas_object_data_get(obj, "gld"); 440 GLData *gld = evas_object_data_get(obj, "gld");
440 if (!gld) 441 if (!gld)
441 { 442 {
442 printf("Unable to get GLData. \n"); 443 printf("Unable to get GLData.\n");
444 fflush(stdout);
443 return; 445 return;
444 } 446 }
445 Evas_GL_API *gl = gld->glapi; 447 Evas_GL_API *gl = gld->glapi;