diff --git a/Foundation/include/Poco/Any.h b/Foundation/include/Poco/Any.h index 00673863d..e05d81f13 100644 --- a/Foundation/include/Poco/Any.h +++ b/Foundation/include/Poco/Any.h @@ -80,7 +80,7 @@ public: Placeholder(): pHolder(0) { - std::memset(holder, 0, sizeof(Placeholder)); + std::memset(holder, 0, sizeof(holder)); } ~Placeholder() @@ -101,8 +101,8 @@ public: bool isEmpty() const { - static char buf[SizeV+1] = {}; - return 0 == std::memcmp(holder, buf, SizeV+1); + static char buf[sizeof(holder)] = {}; + return 0 == std::memcmp(holder, buf, sizeof(holder)); } bool isLocal() const @@ -156,7 +156,7 @@ private: else reinterpret_cast(holder)->~PlaceholderT(); - if (clear) std::memset(holder, 0, sizeof(Placeholder)); + if (clear) std::memset(holder, 0, sizeof(holder)); } }