From e91afbaef120261c80921ff06cea9c78135c57a8 Mon Sep 17 00:00:00 2001 From: Russell Bryant Date: Fri, 5 May 2006 21:43:06 +0000 Subject: [PATCH] fix the return value of gettag() to only return the pointer to the provided tag buffer if the tag was actually found. There is code that checks to see if this result is non-zero to determine whether the tag was found or not. (issue #7092, mikma) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@25060 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- channels/chan_sip.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/channels/chan_sip.c b/channels/chan_sip.c index 2d7c6cd0d2..c13d9a9ce0 100644 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -10795,8 +10795,9 @@ static const char *gettag(const struct sip_request *req, char *header, char *tag sep = strchr(tagbuf, ';'); if (sep) *sep = '\0'; + return tagbuf; } - return tagbuf; + return NULL; } /*! \brief Handle incoming notifications */ -- 2.47.3