From 91fa2122a536770924bb2819bec4b79e76393d08 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Tue, 11 Sep 2012 20:03:02 +0300 Subject: Fix code style and small perfomance issues. --- src/graphicsmanager.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/graphicsmanager.cpp') diff --git a/src/graphicsmanager.cpp b/src/graphicsmanager.cpp index 66502434d..2d2740023 100644 --- a/src/graphicsmanager.cpp +++ b/src/graphicsmanager.cpp @@ -337,10 +337,9 @@ void GraphicsManager::updateTextureFormat() || supportExtension("3DFX_texture_compression_FXT1")) { GLint num; - GLint *formats = nullptr; glGetIntegerv(GL_NUM_COMPRESSED_TEXTURE_FORMATS, &num); logger->log("support %d compressed formats", num); - formats = new GLint[num > 10 ? num : 10]; + GLint *formats = new GLint[num > 10 ? num : 10]; glGetIntegerv(GL_COMPRESSED_TEXTURE_FORMATS, formats); for (int f = 0; f < num; f ++) { -- cgit v1.2.3-60-g2f50