minor
authorNicolas Cornu <nicolas.cornu@ensi-bourges.fr>
Sun, 04 Jul 2010 01:10:51 +0200
changeset 27 fb602f55af15
parent 26 af14f8f5a2b6
child 28 ed7520776c41
minor
jingle/action-handlers.c
jingle/send.c
jingle/send.h
--- a/jingle/action-handlers.c	Sat Jul 03 18:41:36 2010 +0200
+++ b/jingle/action-handlers.c	Sun Jul 04 01:10:51 2010 +0200
@@ -89,6 +89,16 @@
   if(!is_session) { // None of the app is supported
     jingle_send_session_terminate(m, "unsupported-applications");
   }
+
+  is_session = FALSE;  
+  // Do we support any of this xmlns ?
+  for (child = jn->content; child && !is_session; child = child->next) {
+    if(jingle_get_transportfuncs(((JingleContent*)(child->data))->xmlns_trans) != NULL)
+      is_session = TRUE;
+  }
+  if(!is_session) { // None of the transport is supported
+    jingle_send_session_terminate(m, "unsupported-transports");
+  }
 }
 
 void handle_session_terminate(LmMessage *m, JingleNode *jn)
--- a/jingle/send.c	Sat Jul 03 18:41:36 2010 +0200
+++ b/jingle/send.c	Sun Jul 04 01:10:51 2010 +0200
@@ -22,6 +22,8 @@
 #include <glib.h>
 #include <loudmouth/loudmouth.h>
 
+#include <mcabber/utils.h>
+
 #include <jingle/send.h>
 
 void jingle_send_session_terminate(const LmMessage *m, const gchar *reason) {
--- a/jingle/send.h	Sat Jul 03 18:41:36 2010 +0200
+++ b/jingle/send.h	Sun Jul 04 01:10:51 2010 +0200
@@ -1,6 +1,6 @@
 #ifndef __SEND_H__
 #define __SEND_H__ 1
 
-void jingle_send_session_terminate(LmMessage *m, const gchar *reason);
+void jingle_send_session_terminate(const LmMessage *m, const gchar *reason);
 
 #endif