[asterisk-commits] wedhorn: branch 10 r339722 - /branches/10/channels/chan_skinny.c
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Thu Oct 6 18:09:03 CDT 2011
Author: wedhorn
Date: Thu Oct 6 18:08:57 2011
New Revision: 339722
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=339722
Log:
Reject v17 skinny devices in Asterisk10
Small fix for Asterisk10 to reject skinny devices with skinny
firmware version17 and above.
Review: https://reviewboard.asterisk.org/r/1497/
Modified:
branches/10/channels/chan_skinny.c
Modified: branches/10/channels/chan_skinny.c
URL: http://svnview.digium.com/svn/asterisk/branches/10/channels/chan_skinny.c?view=diff&rev=339722&r1=339721&r2=339722
==============================================================================
--- branches/10/channels/chan_skinny.c (original)
+++ branches/10/channels/chan_skinny.c Thu Oct 6 18:08:57 2011
@@ -273,6 +273,9 @@
uint32_t ip;
uint32_t type;
uint32_t maxStreams;
+ uint32_t space;
+ uint8_t protocolVersion;
+ char space2[3] ;
};
#define IP_PORT_MESSAGE 0x0002
@@ -2048,6 +2051,11 @@
struct sockaddr_in sin;
socklen_t slen;
int instance;
+
+ if (letohl(req->data.reg.protocolVersion) >= 17) {
+ ast_log(LOG_WARNING, "Asterisk10 does not support skinny protocol 17 and above. Rejecting device.\n");
+ return 0;
+ }
AST_LIST_LOCK(&devices);
AST_LIST_TRAVERSE(&devices, d, list){
More information about the asterisk-commits
mailing list