example: glview - use delete to deallocate memory
authorAmitesh Singh <amitesh.sh@samsung.com>
Wed, 14 Oct 2015 15:02:51 +0000 (20:32 +0530)
committerAmitesh Singh <amitesh.sh@samsung.com>
Wed, 14 Oct 2015 15:03:13 +0000 (20:33 +0530)
CID: 1327362

src/examples/glview_cxx_example_01.cc

index bcf44d9..b94d8c2 100644 (file)
@@ -98,7 +98,7 @@ init_shaders(GLData *gld)
 
              gl->glGetProgramInfoLog(gld->program, info_len, NULL, info_log);
              printf("Error linking program:\n%s\n", info_log);
-             free(info_log);
+             delete [] info_log;
           }
         gl->glDeleteProgram(gld->program);
         return 0;