summaryrefslogtreecommitdiff
path: root/pjsip/src/pjsip/sip_util.c
diff options
context:
space:
mode:
authorBenny Prijono <bennylp@teluu.com>2006-05-16 13:20:00 +0000
committerBenny Prijono <bennylp@teluu.com>2006-05-16 13:20:00 +0000
commit11e0aa7dac9feb0b09155a73eabc161e9db1d55f (patch)
tree6b07f893c52dbef12144c079faf2caf3874ba768 /pjsip/src/pjsip/sip_util.c
parentca05e325d99bde3c74889348aacc77571f21a0b9 (diff)
Rearrange transaction statefull stuffs in SIP so that it will not be linked when transaction is disabled
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@448 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjsip/src/pjsip/sip_util.c')
-rw-r--r--pjsip/src/pjsip/sip_util.c67
1 files changed, 0 insertions, 67 deletions
diff --git a/pjsip/src/pjsip/sip_util.c b/pjsip/src/pjsip/sip_util.c
index 60f48681..d4f2dbac 100644
--- a/pjsip/src/pjsip/sip_util.c
+++ b/pjsip/src/pjsip/sip_util.c
@@ -1257,73 +1257,6 @@ PJ_DEF(pj_status_t) pjsip_endpt_respond_stateless( pjsip_endpoint *endpt,
/*
- * Send response statefully.
- */
-PJ_DEF(pj_status_t) pjsip_endpt_respond( pjsip_endpoint *endpt,
- pjsip_module *tsx_user,
- pjsip_rx_data *rdata,
- int st_code,
- const pj_str_t *st_text,
- const pjsip_hdr *hdr_list,
- const pjsip_msg_body *body,
- pjsip_transaction **p_tsx )
-{
- pj_status_t status;
- pjsip_tx_data *tdata;
- pjsip_transaction *tsx;
-
- /* Validate arguments. */
- PJ_ASSERT_RETURN(endpt && rdata, PJ_EINVAL);
-
- if (p_tsx) *p_tsx = NULL;
-
- /* Create response message */
- status = pjsip_endpt_create_response( endpt, rdata, st_code, st_text,
- &tdata);
- if (status != PJ_SUCCESS)
- return status;
-
- /* Add the message headers, if any */
- if (hdr_list) {
- const pjsip_hdr *hdr = hdr_list->next;
- while (hdr != hdr_list) {
- pjsip_msg_add_hdr( tdata->msg, pjsip_hdr_clone(tdata->pool, hdr) );
- hdr = hdr->next;
- }
- }
-
- /* Add the message body, if any. */
- if (body) {
- tdata->msg->body = pjsip_msg_body_clone( tdata->pool, body );
- if (tdata->msg->body == NULL) {
- pjsip_tx_data_dec_ref(tdata);
- return status;
- }
- }
-
- /* Create UAS transaction. */
- status = pjsip_tsx_create_uas(tsx_user, rdata, &tsx);
- if (status != PJ_SUCCESS) {
- pjsip_tx_data_dec_ref(tdata);
- return status;
- }
-
- /* Feed the request to the transaction. */
- pjsip_tsx_recv_msg(tsx, rdata);
-
- /* Send the message. */
- status = pjsip_tsx_send_msg(tsx, tdata);
- if (status != PJ_SUCCESS) {
- pjsip_tx_data_dec_ref(tdata);
- } else if (p_tsx) {
- *p_tsx = tsx;
- }
-
- return status;
-}
-
-
-/*
* Get the event string from the event ID.
*/
PJ_DEF(const char *) pjsip_event_str(pjsip_event_id_e e)