Browse Source

More mem*() stuff... sigh...

Adam Ierymenko 6 years ago
parent
commit
752fc0742e
2 changed files with 2 additions and 2 deletions
  1. 1 1
      node/Capability.hpp
  2. 1 1
      node/Tag.hpp

+ 1 - 1
node/Capability.hpp

@@ -426,7 +426,7 @@ public:
 	template<unsigned int C>
 	inline unsigned int deserialize(const Buffer<C> &b,unsigned int startAt = 0)
 	{
-		memset(this,0,sizeof(Capability));
+		*this = Capability();
 
 		unsigned int p = startAt;
 

+ 1 - 1
node/Tag.hpp

@@ -152,7 +152,7 @@ public:
 	{
 		unsigned int p = startAt;
 
-		memset(this,0,sizeof(Tag));
+		*this = Tag();
 
 		_networkId = b.template at<uint64_t>(p); p += 8;
 		_ts = b.template at<uint64_t>(p); p += 8;