]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Merged revisions 301682 via svnmerge from
authorTerry Wilson <twilson@digium.com>
Wed, 12 Jan 2011 21:19:48 +0000 (21:19 +0000)
committerTerry Wilson <twilson@digium.com>
Wed, 12 Jan 2011 21:19:48 +0000 (21:19 +0000)
https://origsvn.digium.com/svn/asterisk/branches/1.6.2

........
  r301682 | twilson | 2011-01-12 15:05:02 -0600 (Wed, 12 Jan 2011) | 9 lines

  Don't reject all SUBSCRIBE auth requests

  When merging another SUBSCRIBE fix from 1.4, some braces were put in
  the wrong place. This patch fixes that.

  (closes issue #18597)
  Reported by: thsgmbh
........

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@301683 65c4cc65-6c06-0410-ace0-fbb531ad65f3

channels/chan_sip.c

index b84e623003178eda26c4f1b051a3e0ef27c308a0..6b047493e86415d6313fefa47eed04964c824a1c 100644 (file)
@@ -23200,10 +23200,10 @@ static int handle_request_subscribe(struct sip_pvt *p, struct sip_request *req,
                                ast_log(LOG_NOTICE, "Failed to authenticate device %s for SUBSCRIBE\n", get_header(req, "From"));
                                transmit_response_reliable(p, "403 Forbidden", req);
                        }
-               }
 
-               pvt_set_needdestroy(p, "authentication failed");
-               return 0;
+                       pvt_set_needdestroy(p, "authentication failed");
+                       return 0;
+               }
        }
 
        /* At this point, authpeer cannot be NULL. Remember we hold a reference,