diff --git a/hecl/blender/BlenderConnection.hpp b/hecl/blender/BlenderConnection.hpp index f3478bdf2..8f1f2781e 100644 --- a/hecl/blender/BlenderConnection.hpp +++ b/hecl/blender/BlenderConnection.hpp @@ -126,6 +126,9 @@ public: m_parent->m_lock = false; } } +#if __GNUC__ + __attribute__((__format__ (__printf__, 2, 3))) +#endif void format(const char* fmt, ...) { if (!m_parent || !m_parent->m_lock) diff --git a/hecl/driver/ToolExtract.hpp b/hecl/driver/ToolExtract.hpp index 590f52be1..de650a0fb 100644 --- a/hecl/driver/ToolExtract.hpp +++ b/hecl/driver/ToolExtract.hpp @@ -218,7 +218,7 @@ public: if (submessageLen) { if (messageLen > half-submessageLen-1) - HECL::Printf(_S("%.*s... "), half-submessageLen-4, message); + HECL::Printf(_S("%.*s... "), half-int(submessageLen)-4, message); else { HECL::Printf(_S("%s"), message); @@ -246,9 +246,9 @@ public: size_t rem = blocks - filled; HECL::Printf(_S("" BOLD "%3d%% ["), iFactor); for (int b=0 ; b