diff --git a/include/hpp/manipulation/handle.hh b/include/hpp/manipulation/handle.hh index 05ca632dd35ae84eceaabecbfd792da1d7e0e6ae..5c366e1828756194e1b364a3cbf30a71be3d7139 100644 --- a/include/hpp/manipulation/handle.hh +++ b/include/hpp/manipulation/handle.hh @@ -183,6 +183,7 @@ class HPP_MANIPULATION_DLLAPI Handle { robot_(robot), clearance_(0), mask_(6, true), + maskComp_(6, false), weakPtr_() {} void init(HandleWkPtr_t weakPtr) { weakPtr_ = weakPtr; } diff --git a/src/handle.cc b/src/handle.cc index 8e5484c60570d051441ebf98f72b4306d99a6d0c..6cb59a768879ceca427cc5fbd068012645a2d7a5 100644 --- a/src/handle.cc +++ b/src/handle.cc @@ -74,6 +74,7 @@ bool isHandleOnFreeflyer(const Handle& handle) { } inline int maskSize(const std::vector<bool>& mask) { + assert(mask.size() == 6); std::size_t res(0); for (std::size_t i = 0; i < 6; ++i) { if (mask[i]) ++res; @@ -98,6 +99,7 @@ inline bool is6Dmask(const std::vector<bool>& mask) { } inline std::vector<bool> complementMask(const std::vector<bool>& mask) { + assert(mask.size() == 6); std::vector<bool> m(6); for (std::size_t i = 0; i < 6; ++i) m[i] = !mask[i]; return m;