CInode::encode_cap_message: add assert for cap

CID 716913 (#1 of 1): Dereference after null check (FORWARD_NULL)
5. var_deref_op: Dereferencing null pointer "cap".

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>