pdr: pldm_entity_association_tree_find(): Early exit on bad arguments

Also identify the conditions in the doxygen commentary in the header.

Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
Change-Id: I6a1dd656a9f888f147c4248b4793355f7ac8e7fc
diff --git a/src/pdr.c b/src/pdr.c
index 3b30329..3ee8886 100644
--- a/src/pdr.c
+++ b/src/pdr.c
@@ -1189,6 +1189,9 @@
 				  pldm_entity *entity)
 {
 	assert(tree != NULL);
+	if (!tree || !entity) {
+		return NULL;
+	}
 
 	pldm_entity_node *node = NULL;
 	entity_association_tree_find(tree->root, entity, &node);