* Noticed that when serv_chat.c sets async_waiting to 1, it also checks to see if...
[citadel.git] / citadel / modules / chat / serv_chat.c
index f0f1e7d6c40f4a73d976372cf27f75cf9c28628d..028f2833b821716f529323d3c2f53e5d51225ddc 100644 (file)
@@ -650,12 +650,7 @@ void add_xmsg_to_context(struct CitContext *ccptr, struct ExpressMessage *newmsg
        /* If the target context is a session which can handle asynchronous
         * messages, go ahead and set the flag for that.
         */
-       if (ccptr->is_async) {
-               ccptr->async_waiting = 1;
-               if (ccptr->state == CON_IDLE) {
-                       ccptr->state = CON_READY;
-               }
-       }
+       set_async_waiting(ccptr);
 }