[aseprite] 187/250: Avoid warning on clang using side-effect function inside typeid()

Tobias Hansen thansen at moszumanska.debian.org
Sun Dec 20 15:27:29 UTC 2015


This is an automated email from the git hooks/post-receive script.

thansen pushed a commit to branch master
in repository aseprite.

commit 60f0c5bcf753095f9d1caa0ec838826a78a25513
Author: David Capello <davidcapello at gmail.com>
Date:   Fri Oct 16 16:33:44 2015 -0300

    Avoid warning on clang using side-effect function inside typeid()
---
 src/app/ui/document_view.cpp | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/app/ui/document_view.cpp b/src/app/ui/document_view.cpp
index 1c7de06..d667831 100644
--- a/src/app/ui/document_view.cpp
+++ b/src/app/ui/document_view.cpp
@@ -129,13 +129,15 @@ protected:
       return Editor::onProcessMessage(msg);
     }
     catch (const std::exception& ex) {
+      EditorState* state = getState().get();
+
       Console console;
       Console::showException(ex);
       console.printf("\nInternal details:\n"
         "- Message type: %d\n"
         "- Editor state: %s\n",
         msg->type(),
-        getState() ? typeid(*getState().get()).name(): "None");
+        state ? typeid(*state).name(): "None");
       return false;
     }
   }

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/aseprite.git



More information about the Pkg-games-commits mailing list