diff -r 7df2fb9a2365 -r d4d50e62098b jingle/action-handlers.c --- a/jingle/action-handlers.c Fri Aug 13 18:10:46 2010 +0200 +++ b/jingle/action-handlers.c Fri Aug 13 18:39:25 2010 +0200 @@ -385,10 +385,19 @@ void handle_session_terminate(JingleNode *jn) { JingleSession *sess; + GSList *el; + SessionContent *sc; + if ((sess = session_find(jn)) == NULL) { jingle_send_iq_error(jn->message, "cancel", "item-not-found", "unknown-session"); return; } + + for (el = sess->content; el; el = el->next) { + sc = (SessionContent*)el->data; + sc->appfuncs->stop(sc->description); + session_remove_sessioncontent(sess, sc->name); + } session_delete(sess); jingle_ack_iq(jn->message); }