Include Expires header for SIP PUBLISH requests

RFC3903 requres SIP PUBLISH requests to have Expires headers, so add
them.

Review: https://reviewboard.asterisk.org/r/2003/
Patch-by: gareth
........

Merged revisions 370014 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 370015 from http://svn.asterisk.org/svn/asterisk/branches/10


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@370016 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Kinsey Moore 2012-07-12 20:06:23 +00:00
parent 65fe6976ae
commit c1354af599
1 changed files with 1 additions and 1 deletions

View File

@ -10918,7 +10918,7 @@ static int respprep(struct sip_request *resp, struct sip_pvt *p, const char *msg
add_header(resp, "Session-Expires", se_hdr);
}
if (msg[0] == '2' && (p->method == SIP_SUBSCRIBE || p->method == SIP_REGISTER)) {
if (msg[0] == '2' && (p->method == SIP_SUBSCRIBE || p->method == SIP_REGISTER || p->method == SIP_PUBLISH)) {
/* For registration responses, we also need expiry and
contact info */
char tmp[256];