Fixed memory issues related to AddClientCB
AddClientCB had a weak memory-guarantee that caused 3 values to be
leaked in certain conditions. This will prevent those from happening.
The result-setting is done in order to ensure that the values are always
properly free'd.
Change-Id: I027fab84ddf62526d51a6e7e35dd54a96acbb48d
Signed-off-by: Erich Keane <erich.keane@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/502
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Sachin Agrawal <sachin.agrawal@intel.com>
Reviewed-by: Sashi Penta <sashi.kumar.penta@intel.com>