Commit e8f80e97 authored by Pekka Pessi's avatar Pekka Pessi

nua_session.c: remove redundant check from session_get_description()

MeeGo Coverity issue CID#7512
parent 4df0ebb9
......@@ -4538,9 +4538,11 @@ int session_get_description(sip_t const *sip,
if (pl == NULL)
return 0;
else if (pl->pl_len == 0 || pl->pl_data == NULL)
if (pl->pl_len == 0 || pl->pl_data == NULL)
return 0;
else if (ct == NULL)
if (ct == NULL)
/* Be bug-compatible with our old gateways */
SU_DEBUG_3(("nua: no %s, assuming %s\n",
"Content-Type", SDP_MIME_TYPE));
......@@ -4554,9 +4556,6 @@ int session_get_description(sip_t const *sip,
else
matching_content_type = 1;
if (pl == NULL)
return 0;
if (!matching_content_type) {
/* Make sure we got SDP */
if (pl->pl_len < 3 || !su_casenmatch(pl->pl_data, "v=0", 3))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment