jingle-ft/filetransfer.c
changeset 143 cd97a18dd0b9
parent 142 f513b0bc039a
child 145 bde23b68e126
equal deleted inserted replaced
142:f513b0bc039a 143:cd97a18dd0b9
   100   .next            = NULL,
   100   .next            = NULL,
   101 };
   101 };
   102 
   102 
   103 
   103 
   104 /**
   104 /**
   105  * \fn static gconstpointer check(JingleContent *cn, GError **err)
   105  * @brief Check if a node description with xmlns of JFT is correct 
   106  * \brief Check if a node description with xmlns of JFT is correct 
       
   107  *
   106  *
   108  * \param cn the jinglecontent a node description
   107  * @param cn the jinglecontent a node description
   109  * \param err contain an error of the domain JINGLE_CHECK_ERROR
   108  * @param err contain an error of the domain JINGLE_CHECK_ERROR
   110  * \return a gconstpointer, which is a new allocated JingleFT
   109  * @return a gconstpointer, which is a new allocated JingleFT
   111  */
   110  */
   112 static gconstpointer check(JingleContent *cn, GError **err)
   111 static gconstpointer check(JingleContent *cn, GError **err)
   113 {
   112 {
   114   JingleFT *ft = NULL;
   113   JingleFT *ft = NULL;
   115   LmMessageNode *node;
   114   LmMessageNode *node;
   198 
   197 
   199   return (gconstpointer) ft;
   198   return (gconstpointer) ft;
   200 }
   199 }
   201 
   200 
   202 /**
   201 /**
   203  * \fn static gboolean handle(JingleAction action, gconstpointer data, LmMessageNode *node)
   202  * @brief A function to handle incoming jingle action
   204  * \brief handle a function to handle action which are not "current"
   203  * @param action The action which have been received
   205  *
   204  * @param data   Contain the JingleFT of the content concerned
   206  * \param action the action which have been received
   205  * @param node   The node himself
   207  * \param data contain the JingleFT of the content concerned
   206  * @return       TRUE if the action was handled, FALSE otherwise
   208  * \param node the node himself
       
   209  * \return a gconstpointer, which is a new allocated JingleFT
       
   210  */
   207  */
   211 static gboolean handle(JingleAction action, gconstpointer data,
   208 static gboolean handle(JingleAction action, gconstpointer data,
   212                           LmMessageNode *node)
   209                        LmMessageNode *node)
   213 {
   210 {
   214   if (action == JINGLE_SESSION_INFO) {
   211   if (action == JINGLE_SESSION_INFO) {
   215     if (!g_strcmp0(lm_message_node_get_attribute(node, "xmlns"),
   212     if (!g_strcmp0(lm_message_node_get_attribute(node, "xmlns"),
   216                    NS_JINGLE_APP_FT_INFO)
   213                    NS_JINGLE_APP_FT_INFO)
   217         && !g_strcmp0(node->name, "hash")) {
   214         && !g_strcmp0(node->name, "hash")) {