From 8cd0977a3688fa705c83867c57505a47b9269369 Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Sun, 8 Jan 2023 16:34:43 +0000 Subject: Fix up all the static analyzer warnings --- gfx/models/texture.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'gfx/models') diff --git a/gfx/models/texture.cpp b/gfx/models/texture.cpp index 942cedf..ef6d7e7 100644 --- a/gfx/models/texture.cpp +++ b/gfx/models/texture.cpp @@ -48,8 +48,8 @@ Texture::save(const glTexture & texture, GLenum format, GLenum type, const glm:: { using TGAHead = std::array; - size_t dataSize = (static_cast(size.x * size.y * channels)); - size_t fileSize = dataSize + sizeof(TGAHead); + const size_t dataSize = (static_cast(size.x * size.y * channels)); + const size_t fileSize = dataSize + sizeof(TGAHead); filesystem::fh out {path, O_RDWR | O_CREAT, 0660}; out.truncate(fileSize); -- cgit v1.2.3