[asterisk-bugs] [Asterisk 0016021]: [patch] sippeers loaded with realtime are treated as type=friends, no matter what type is in the db

Asterisk Bug Tracker noreply at bugs.digium.com
Tue Oct 6 15:25:59 CDT 2009


A NOTE has been added to this issue. 
====================================================================== 
https://issues.asterisk.org/view.php?id=16021 
====================================================================== 
Reported By:                Guggemand
Assigned To:                
====================================================================== 
Project:                    Asterisk
Issue ID:                   16021
Category:                   Channels/chan_sip/General
Reproducibility:            always
Severity:                   major
Priority:                   normal
Status:                     acknowledged
Target Version:             1.6.1.8
Asterisk Version:           1.6.1.6 
JIRA:                        
Regression:                 No 
Reviewboard Link:            
SVN Branch (only for SVN checkouts, not tarball releases): N/A 
SVN Revision (number only!):  
Request Review:              
====================================================================== 
Date Submitted:             2009-10-05 12:28 CDT
Last Modified:              2009-10-06 15:25 CDT
====================================================================== 
Summary:                    [patch] sippeers loaded with realtime are treated as
type=friends, no matter what type is in the db
Description: 
When using realtime sippeers the peers show up in both

sip show peer <name> load
sip show user <name> load

They are also matched by this code in chan_sip.c, even though they have
type=peer
/* First find devices based on username (avoid all type=peer's) */
peer = find_peer(of, NULL, TRUE, FINDUSERS, FALSE);

====================================================================== 

---------------------------------------------------------------------- 
 (0111930) Guggemand (reporter) - 2009-10-06 15:25
 https://issues.asterisk.org/view.php?id=16021#c111930 
---------------------------------------------------------------------- 
With type=user in the database the user is never loaded.
With type=friend in the database the friend is loaded, and shows up in
sip show peers and sip show users (if cache is enabled)

With type=peer in the database the peer is loaded, and shows up in
sip show peers, but not in sip show users (if cache is enabled)

Getting realtime_peer to return both peers and users, and getting
find_peer to 
return the right types when using realtime should be fixed by the attached
patch 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2009-10-06 15:25 Guggemand      Note Added: 0111930                          
======================================================================




More information about the asterisk-bugs mailing list