Add some checks on Obj::set
Add some checks on Obj::set

Change-Id: I40468be87ca19c224c3dffcabcb48e27254c4373

realm/realm-core,realm/realm-core,realm/realm-core,realm/realm-core,realm/realm-core,realm/realm-core,realm/realm-core