[svn-commits] mvanbaak: trunk r135332 - /trunk/channels/chan_skinny.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Sat Aug 2 08:56:00 CDT 2008


Author: mvanbaak
Date: Sat Aug  2 08:56:00 2008
New Revision: 135332

URL: http://svn.digium.com/view/asterisk?view=rev&rev=135332
Log:
make this work again, and not segfault on device registration

Modified:
    trunk/channels/chan_skinny.c

Modified: trunk/channels/chan_skinny.c
URL: http://svn.digium.com/view/asterisk/trunk/channels/chan_skinny.c?view=diff&rev=135332&r1=135331&r2=135332
==============================================================================
--- trunk/channels/chan_skinny.c (original)
+++ trunk/channels/chan_skinny.c Sat Aug  2 08:56:00 2008
@@ -4166,7 +4166,7 @@
 
 static int handle_register_message(struct skinny_req *req, struct skinnysession *s)
 {
-	struct skinny_device *d = s->device;
+	struct skinny_device *d = NULL;
 	char name[16];
 	int res;
 
@@ -4184,6 +4184,8 @@
 		return 0;
 	}
 	ast_verb(3, "Device '%s' successfully registered\n", name);
+
+	d = s->device;
 	
 	if (!(req = req_alloc(sizeof(struct register_ack_message), REGISTER_ACK_MESSAGE)))
 		return -1;




More information about the svn-commits mailing list