Move whisper()'s away message checking to the cprivmsg path.
authorMichael Poole <mdpoole@troilus.org>
Tue, 14 Aug 2007 03:56:46 +0000 (03:56 +0000)
committerMichael Poole <mdpoole@troilus.org>
Tue, 14 Aug 2007 03:56:46 +0000 (03:56 +0000)
git-svn-id: file:///home/klmitch/undernet-ircu/undernet-ircu-svn/ircu2/branches/u2_10_12_branch@1830 c9e4aea6-c8fd-4c43-8297-357d70d61c8c

ChangeLog
ircd/s_user.c

index 49c14fe6ceaa6ceed89769fbcf56bab5e8fc32dd..c357292a407379617b93cdcfd4ff015b667040aa 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2007-08-13  Michael Poole <mdpoole@troilus.org>
+
+       * ircd/s_user.c (whipser): CNOTICEs should not trigger away
+       messages, only CPRIVMSGs.
+
 2007-08-13  Michael Poole <mdpoole@troilus.org>
 
        * ircd/m_who.c (m_who): Reorder responses and change the
index a859ef8868878f53365108637d1af974e61429a6..b6d5d41bc0ffc2856373f8fbed970b4c65b04576 100644 (file)
@@ -796,12 +796,14 @@ int whisper(struct Client* source, const char* nick, const char* channel,
   if (is_silenced(source, dest))
     return 0;
           
-  if (cli_user(dest)->away)
-    send_reply(source, RPL_AWAY, cli_name(dest), cli_user(dest)->away);
   if (is_notice)
     sendcmdto_one(source, CMD_NOTICE, dest, "%C :%s", dest, text);
   else
+  {
+    if (cli_user(dest)->away)
+      send_reply(source, RPL_AWAY, cli_name(dest), cli_user(dest)->away);
     sendcmdto_one(source, CMD_PRIVATE, dest, "%C :%s", dest, text);
+  }
   return 0;
 }