The logic for removing the trailing comma in the event that a resource
was improperly added was reversed. This removes the "NOT" to correct
this so that the comma is only removed in the event that it was actually
added.
Change-Id: I4f6037198ef7a67cd3d83d77f5e27aebb7cc0b28
Signed-off-by: Erich Keane <erich.keane@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1155
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
if (result != OC_STACK_OK)
{
// if this failed, we need to remove the comma added above.
- if(!firstLoopDone)
+ if(firstLoopDone)
{
ptr--;
*ptr = '\0';