added gnutls backend and moved backend code into new files
[ircu2.10.12-pk.git] / ircd / m_endburst.c
index aea0decf8ae8544f839e84a80dd5a9f1d6cc78e0..46d51ae0a105ad8f84bc684ef35dcbb081ad982b 100644 (file)
@@ -126,13 +126,12 @@ int ms_end_of_burst(struct Client* cptr, struct Client* sptr, int parc, char* pa
   /* Count through channels... */
   for (chan = GlobalChannelList; chan; chan = next_chan) {
     next_chan = chan->next;
-
-    if (!chan->members) { /* empty channel */
-      if ((chan->mode.mode & MODE_BURSTADDED))
-       sub1_from_channel(chan); /* New empty channel, schedule it for removal. */
-    }
-
-    chan->mode.mode &= ~MODE_BURSTADDED;
+    if (!chan->members && (chan->mode.mode & MODE_BURSTADDED)) {
+      /* Newly empty channel, schedule it for removal. */
+      chan->mode.mode &= ~MODE_BURSTADDED;
+      sub1_from_channel(chan);
+   } else
+      chan->mode.mode &= ~MODE_BURSTADDED;
   }
 
   return 0;