[Shadowirc-commits] CVS: shadowirc/src ServerCommands.c,1.22,1.23 plugins.h,1.31,1.32
Status: Alpha
Brought to you by:
dshadow
|
From: John B. <ds...@us...> - 2005-02-07 05:46:04
|
Update of /cvsroot/shadowirc/shadowirc/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23736/src Modified Files: ServerCommands.c plugins.h Log Message: Correctly route notices to @#channel target Index: ServerCommands.c =================================================================== RCS file: /cvsroot/shadowirc/shadowirc/src/ServerCommands.c,v retrieving revision 1.22 retrieving revision 1.23 diff -u -d -r1.22 -r1.23 --- ServerCommands.c 26 Jan 2005 03:27:30 -0000 1.22 +++ ServerCommands.c 7 Feb 2005 05:45:51 -0000 1.23 @@ -87,7 +87,7 @@ Str255 dispFrom; pServerNOTICEDataRec p; MWPtr mw; - char ign=IsIgnoredNickUser(from, fromuser); + char ign = IsIgnoredNickUser(from, fromuser); if(!doCTCP(from, fromuser, target, ls, true, ign, link)) { @@ -112,9 +112,20 @@ p.dontSound = false; p.displayUserHost = mainPrefs->showUserHostsWithMsgs && !p.fromServer; p.redirect = 0; + p.wallchops = 0; - if((p.targChan = ((p.chan=ChFind(target, link))!=0)) == 0) + if(target[1] == '@') { + p.wallchops = 1; + pdelete(target, 1, 1); + } + + p.chan = ChFind(target, link); + p.targChan = p.chan != 0; + + if(!p.targChan) + { + p.wallchops = 0; if((p.targMe = pstrcasecmp(target, link->CurrentNick)) == 0) p.targOther=1; } Index: plugins.h =================================================================== RCS file: /cvsroot/shadowirc/shadowirc/src/plugins.h,v retrieving revision 1.31 retrieving revision 1.32 diff -u -d -r1.31 -r1.32 --- plugins.h 15 Aug 2004 07:18:03 -0000 1.31 +++ plugins.h 7 Feb 2005 05:45:51 -0000 1.32 @@ -532,8 +532,8 @@ char displayUserHost; //If true, displays the person's userhost. defaults to targMe && mainPrefs->showUserHostsWithMsgs char toConsole; //Force to console char dontSound; //If true, don't play a sound. - -char unused[3]; + char wallchops; //If true, message was targed to @#channel +char unused[2]; MWPtr redirect; } pServerNOTICEDataRec, *pServerNOTICEDataPtr; |