[gaim-migrate @ 13308]

Thu, 04 Aug 2005 09:19:57 +0000

author
Thomas Butter <tbutter@users.sourceforge.net>
date
Thu, 04 Aug 2005 09:19:57 +0000
changeset 11190
16f02ac58a38
parent 11189
5ac07336091e
child 11191
c49474dca792

[gaim-migrate @ 13308]
- UDP fix
- 501 response on unknown requests

src/protocols/simple/simple.c file | annotate | diff | comparison | revisions
--- a/src/protocols/simple/simple.c	Thu Aug 04 09:10:11 2005 +0000
+++ b/src/protocols/simple/simple.c	Thu Aug 04 09:19:57 2005 +0000
@@ -378,7 +378,7 @@
 
 	
 	buf = g_strdup_printf("%s %s SIP/2.0\r\n"
-			"Via: SIP/2.0/TCP %s:%d;branch=%s\r\n"
+			"Via: SIP/2.0/%s %s:%d;branch=%s\r\n"
 			"From: <sip:%s@%s>;tag=%s\r\n"
 			"To: <%s>%s%s\r\n"
 			"Max-Forwards: 10\r\n"
@@ -389,6 +389,7 @@
 			"Content-Length: %d\r\n\r\n%s",
 			method,
 			url,
+			sip->udp ? "UDP" : "TCP",
 			sip->ip,	
 			sip->listenport,
 			branch,
@@ -826,6 +827,9 @@
 			process_incoming_subscribe(sip, msg);
 			found = 1;
 		}
+		if(!found) {
+	                send_sip_response(sip->gc, msg, 501, "Not implemented", NULL);
+		}
 	} else { // response
 		struct transaction *trans = transactions_find(sip, msg);
 		if(trans) {

mercurial