summaryrefslogtreecommitdiff
path: root/channels
diff options
context:
space:
mode:
authorLuigi Rizzo <rizzo@icir.org>2006-10-11 09:17:05 +0000
committerLuigi Rizzo <rizzo@icir.org>2006-10-11 09:17:05 +0000
commit2eeaeaa7a78fd6459573c4835b68d8f8681bcecb (patch)
treef87df0e8b59cc69667ac6d2c90453a904fee8811 /channels
parent510b9f04c0c25476d8c63a0a81630d85e1c96575 (diff)
handle_response_peerpoke() does not need to return anything.
(Reindentation in the next commit.) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@44853 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'channels')
-rw-r--r--channels/chan_sip.c15
1 files changed, 7 insertions, 8 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index 66087f326..e6a60203d 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -1491,7 +1491,6 @@ static int local_attended_transfer(struct sip_pvt *transferer, struct sip_dual *
/*------Response handling functions */
static void handle_response_invite(struct sip_pvt *p, int resp, char *rest, struct sip_request *req, int seqno);
static void handle_response_refer(struct sip_pvt *p, int resp, char *rest, struct sip_request *req, int seqno);
-static int handle_response_peerpoke(struct sip_pvt *p, int resp, struct sip_request *req);
static int handle_response_register(struct sip_pvt *p, int resp, char *rest, struct sip_request *req, int ignore, int seqno);
static void handle_response(struct sip_pvt *p, int resp, char *rest, struct sip_request *req, int ignore, int seqno);
@@ -11679,15 +11678,17 @@ static int handle_response_register(struct sip_pvt *p, int resp, char *rest, str
}
/*! \brief Handle qualification responses (OPTIONS) */
-static int handle_response_peerpoke(struct sip_pvt *p, int resp, struct sip_request *req)
+static void handle_response_peerpoke(struct sip_pvt *p, int resp, struct sip_request *req)
{
struct sip_peer *peer;
int pingtime;
struct timeval tv;
+ int statechanged = 0;
+ int newstate = 0;
+
+ if (resp == 100)
+ return;
- if (resp != 100) {
- int statechanged = 0;
- int newstate = 0;
peer = p->relatedpeer;
gettimeofday(&tv, NULL);
pingtime = ast_tvdiff_ms(tv, peer->ps);
@@ -11728,8 +11729,6 @@ static int handle_response_peerpoke(struct sip_pvt *p, int resp, struct sip_requ
peer->pokeexpire = ast_sched_add(sched, DEFAULT_FREQ_NOTOK, sip_poke_peer_s, peer);
else
peer->pokeexpire = ast_sched_add(sched, DEFAULT_FREQ_OK, sip_poke_peer_s, peer);
- }
- return 1;
}
/*! \brief Immediately stop RTP, VRTP and UDPTL as applicable */
@@ -11782,7 +11781,7 @@ static void handle_response(struct sip_pvt *p, int resp, char *rest, struct sip_
Well, as long as it's not a 100 response... since we might
need to hang around for something more "definitive" */
- res = handle_response_peerpoke(p, resp, req);
+ handle_response_peerpoke(p, resp, req);
} else if (ast_test_flag(&p->flags[0], SIP_OUTGOING)) {
switch(resp) {
case 100: /* 100 Trying */