pdr: Return success for pldm_pdr_find_child_container_id_range_exclude()

The API finds the child container id and once its found there is no
necessity to loop further. The function was also returning -ENOKEY even
if a child node meeting the criteria is found. Hence, we are returning
from the loop once the container id is found.

This commit addresses the comment in
https://gerrit.openbmc.org/c/openbmc/libpldm/+/63615/29..31/src/pdr.c#b426

Fixes: 5dc025719dc3 (“pdr: Add pldm_pdr_find_container_id_range_exclude() API”)
Change-Id: Ib96de317abcffb043e98094b3b7b4552ec63b9bc
Signed-off-by: Pavithra Barithaya <pavithra.b@ibm.com>
diff --git a/src/pdr.c b/src/pdr.c
index a78593c..3b86f88 100644
--- a/src/pdr.c
+++ b/src/pdr.c
@@ -419,6 +419,7 @@
 		if (is_container_entity_type &&
 		    is_container_entity_instance_number) {
 			*container_id = le16toh(child->entity_container_id);
+			return 0;
 		}
 	}
 	return -ENOKEY;