From 6f5d88a89856468c4f09fb4f43631b8fb09e2448 Mon Sep 17 00:00:00 2001 From: Joshua Granick Date: Sun, 27 Jul 2014 19:37:45 -0700 Subject: [PATCH] Fix PNG header check --- project/src/graphics/PNG.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/project/src/graphics/PNG.cpp b/project/src/graphics/PNG.cpp index 4a6ac9f3b..af634115a 100644 --- a/project/src/graphics/PNG.cpp +++ b/project/src/graphics/PNG.cpp @@ -88,13 +88,17 @@ namespace lime { if (!file) return false; // verify the PNG signature - /*int read = lime::fread (png_sig, PNG_SIG_SIZE, 1, file); + int read = lime::fread (png_sig, PNG_SIG_SIZE, 1, file); if (png_sig_cmp (png_sig, 0, PNG_SIG_SIZE)) { lime::fclose (file); return false; - }*/ + } else { + + lime::fseek (file, 0, 0); + + } } else {