mgcp: We do not need to check for talloc_free
Simplify the code and remove null check for the two strings.
diff --git a/openbsc/src/libmgcp/mgcp_protocol.c b/openbsc/src/libmgcp/mgcp_protocol.c
index 54af15b..86f361c 100644
--- a/openbsc/src/libmgcp/mgcp_protocol.c
+++ b/openbsc/src/libmgcp/mgcp_protocol.c
@@ -996,15 +996,11 @@
endp->ci = CI_UNUSED;
endp->allocated = 0;
- if (endp->callid) {
- talloc_free(endp->callid);
- endp->callid = NULL;
- }
+ talloc_free(endp->callid);
+ endp->callid = NULL;
- if (endp->local_options) {
- talloc_free(endp->local_options);
- endp->local_options = NULL;
- }
+ talloc_free(endp->local_options);
+ endp->local_options = NULL;
mgcp_rtp_end_reset(&endp->bts_end);
mgcp_rtp_end_reset(&endp->net_end);