Skip to content

Commit

Permalink
ims_registrar_pcscf: update registered state to pending registration …
Browse files Browse the repository at this point in the history
…if contact exists
  • Loading branch information
herlesupreeth authored and miconda committed Feb 28, 2024
1 parent 17bdbd3 commit 4fb8acc
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions src/modules/ims_registrar_pcscf/save.c
Original file line number Diff line number Diff line change
Expand Up @@ -477,8 +477,15 @@ int save_pending(struct sip_msg *_m, udomain_t *_d)
ul.unlock_udomain(_d, &ci.via_host, ci.via_port, ci.via_prot);
return -2;
}
} else {
LM_DBG("Contact already exists - not doing anything for now\n");
} else if(pcontact->reg_state == PCONTACT_DEREG_PENDING_PUBLISH) {
LM_DBG("Contact already exists - Updating contact [%.*s]: setting "
"state to PCONTACT_REG_PENDING\n",
pcontact->aor.len, pcontact->aor.s);

memset(&ci_, 0, sizeof(struct pcontact_info));
ci_.reg_state = PCONTACT_REG_PENDING;
ci_.num_service_routes = 0;
ul.update_pcontact(_d, &ci_, pcontact);
}
}

Expand Down

0 comments on commit 4fb8acc

Please sign in to comment.