Commit Graph

28 Commits

Author SHA1 Message Date
Kevin Easton
3aa7f7765f Remove non-standard arithmetic on void *, and get offsetof() from <stddef.h> instead
of rolling our own.

Fixes building on Irix.


git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@110 13b04d17-f746-0410-82c6-800466cd88b0
2011-02-02 12:34:13 +00:00
Kevin Easton
08cca81993 Rework cset functions to remove non-standard void * arithmetic.
Fixes compiling on Irix.


git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@108 13b04d17-f746-0410-82c6-800466cd88b0
2011-02-02 12:13:54 +00:00
Kevin Easton
d1e13bc526 Show correct message ("Remote end closed connection") when we get EOF
on a socket.

I also added a wrapper function around strerror() for dgets_errno, since
we did the same thing in a few places.  This all needs to be cleaned up
a little - the -1 value we use could in theory clash with an actual
errno error number.


git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@104 13b04d17-f746-0410-82c6-800466cd88b0
2010-09-30 13:26:06 +00:00
Kevin Easton
7a59da1f2e Add /FSET WHOIS_CALLERID for +g mode notification on hybrid & ratbox.
This is numeric 716.  Hybrid shows it in WHOIS, and both show it when you
try to PRIVMSG someone who is +g (similar to AWAY).  So I've formatted it
to match the WHOIS block.

I also took the chance to fix up the ordering of the fsets, and remove
a bunch of redundant setting of default values.


git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@103 13b04d17-f746-0410-82c6-800466cd88b0
2010-09-30 12:48:28 +00:00
Kevin Easton
f71e26acc7 Correct count in /CLONES (reported by t3gah), and format output nicely
using an /fset.

/CLONES now uses the same formats as the /U command.  Also tweaked those
formats at the same time.



git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@98 13b04d17-f746-0410-82c6-800466cd88b0
2010-09-06 13:40:13 +00:00
Kevin Easton
d6c105861c Fix auto-away time strangeness when server reconnection happens.
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@94 13b04d17-f746-0410-82c6-800466cd88b0
2010-09-05 08:37:04 +00:00
Kevin Easton
223926fdf2 Fix up /WILN, /WILC and /WILCR. last_ctcp is now the last CTCP request
recieved; last_ctcp_reply is the last reply recieved (used by /RELCR etc.)

All of the /WI* commands now do a /WII style full whois request.


git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@88 13b04d17-f746-0410-82c6-800466cd88b0
2010-06-26 14:43:22 +00:00
Kevin Easton
789ed916cd Backport changes from epic5 to make recv_nick, sent_nick and sent_body
per-server, and apply new version of do_oops from flewid (the BX2 version). 

This means that /oops, "/query .", "/query ,", "/msg ." and "/msg ," are now
per-server, along with the $. $, and $B aliases.



git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@87 13b04d17-f746-0410-82c6-800466cd88b0
2010-06-26 08:18:34 +00:00
Kevin Easton
8c099a4ce3 Fix alloca build warnings on freebsd (backport from epic).
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@83 13b04d17-f746-0410-82c6-800466cd88b0
2010-03-07 07:24:12 +00:00
Kevin Easton
abb5e06233 Modify the RPL_WHOISACTUALLY numeric handling to work on Bahamut as well.
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@82 13b04d17-f746-0410-82c6-800466cd88b0
2009-12-10 13:07:23 +00:00
Kevin Easton
7ac4b8520c Convert my_stricmp, my_strnicmp and wild_match from unsigned char * to char *.
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@80 13b04d17-f746-0410-82c6-800466cd88b0
2009-11-24 10:21:30 +00:00
Kevin Easton
b2a282feaa Fix a refcounting issue in the whowas list handling.
When a user in one of the whowas lists rejoins, their entry is removed from
the whowas list (and added to a channel nicklist).  However the count of
entries in the whowas list wasn't being decremented, so eventually the client
thinks the lists are full when they're really empty... at this point only one
user at a time can be in the lists (so /WHOLEFT after a netsplit would only
show one user).



git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@77 13b04d17-f746-0410-82c6-800466cd88b0
2009-10-16 12:35:56 +00:00
Kevin Easton
0fc23ba148 Reinstate a new version of RPL_WHOISACTUALLY numeric handling.
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@72 13b04d17-f746-0410-82c6-800466cd88b0
2009-09-21 14:14:28 +00:00
Kevin Easton
c0d80d4c8c Merge updated server list from 1.1 branch.
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@61 13b04d17-f746-0410-82c6-800466cd88b0
2009-08-15 11:21:48 +00:00
Kevin Easton
1b370475ec Fixed the defaults for JOIN_NEW_WINDOW_TYPE and QUERY_NEW_WINDOW_TYPE.
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@59 13b04d17-f746-0410-82c6-800466cd88b0
2009-08-11 14:08:53 +00:00
Kevin Easton
147ea72710 Some cleanups in quit message handling. Fixed a bug where a quit from a user
that isn't in a channel with the client (god knows how *that* happens, but
someone reported the bug...) could crash the client, because a NULL pointer 
is passed to logmsg().  The bug didn't show under glibc because it handles
the NULL pointer OK.


git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@58 13b04d17-f746-0410-82c6-800466cd88b0
2008-07-07 11:55:00 +00:00
Kevin Easton
708e4b6f19 Change NICKSORT_OP to NICKSORT_STAT (sorts nicks by channel status -
chanop first, then halops, voices and others).  Added /SCAN -stat
to sort nicks using NICKSORT_OP.  Removed NICKSORT_VOICE - it was broken
anyway.

Removed "scan" plugin, this functionality is now covered by /SCAN -stat.


git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@52 13b04d17-f746-0410-82c6-800466cd88b0
2008-06-14 06:45:05 +00:00
Kevin Easton
b5741b6ee2 Add %G (halfop symbol) to the default status line.
Also change the meaning of %= in the status line so that the voice
symbol is shown whether or not the user is opped.


git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@50 13b04d17-f746-0410-82c6-800466cd88b0
2008-06-12 14:55:00 +00:00
Kevin Easton
b057339be6 Substantial rewrite of /SCAN (do_scan). Now provides total channel nick
count as well as filtered nick count to the header and footer formats -
default header formats updated to show it.


git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@48 13b04d17-f746-0410-82c6-800466cd88b0
2008-06-12 14:50:45 +00:00
Kevin Easton
1e81f1ed7b Rework formatting of /NAMES and /SCAN output.
The formatting of /NAMES and /SCAN output has been substantially reworked.
The old /FSETs NAMES_BOTCOLOR, NAMES_FRIENDCOLOR, NAMES_NICKCOLOR,
NAMES_OPCOLOR, NAMES_SHITCOLOR and NAMES_VOICECOLOR have been replaced
with these new /FSETs:

....................NAMES_NICK %B$[10]0
................NAMES_NICK_BOT %G$[10]0
.............NAMES_NICK_FRIEND %Y$[10]0
.................NAMES_NICK_ME %W$[10]0
...............NAMES_NICK_SHIT %R$[10]0
....................NAMES_USER %K[ %n$1-%K]
.............NAMES_USER_CHANOP %K[%C$0%n$1-%K]
..............NAMES_USER_IRCOP %K[%R$0%n$1-%K]
..............NAMES_USER_VOICE %K[%M$0%n$1-%K]

The NAMES_NICK formats control how the nick itself is displayed, depending
on the status of the nick as recognised by BitchX (the priority order is
NAMES_NICK_ME > NAMES_NICK_BOT > NAMES_NICK_FRIEND > NAMES_NICK_SHIT >
NAMES_NICK).  The NAMES_USER formats control how the overall entry appears in
the /NAMES or /SCAN line, depending on the channel status of the nick (the
priority order is NAMES_USER_CHANOP > NAMES_USER_VOICE > NAMES_USER_IRCOP >
NAMES_USER).

You'll need to update any scripts or custom formats that altered the old
formats.  If you just use the defaults, the main difference you'll see is
that your own nick is now shown in white, and voiced users are shown with
the '+' sent by the server instead of the 'v'.  You can go back to the old
look by setting these formats:

/FSET NAMES_NICK_ME %B$[10]0
/FSET NAMES_USER_VOICE %K[%Mv%n$1-%K]



git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@46 13b04d17-f746-0410-82c6-800466cd88b0
2008-05-27 04:53:19 +00:00
Kevin Easton
d809649484 Merge r23 from branches/ircii-pana-1.1
Changes to allow compiling on gcc-4.0.


git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@40 13b04d17-f746-0410-82c6-800466cd88b0
2008-05-07 11:07:31 +00:00
Kevin Easton
ee2fe058c2 Merge r11,r12,r13 from branches/ircii-pana-1.1
Implements new method to find vhosts (fixes CVE-2007-5839).


git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@38 13b04d17-f746-0410-82c6-800466cd88b0
2008-05-07 10:57:26 +00:00
Kevin Easton
285b02c36a Add $ishalfop(<nick> <channel>) scripting function, as per EPIC.
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@34 13b04d17-f746-0410-82c6-800466cd88b0
2008-05-07 08:48:49 +00:00
Kevin Easton
998453de9f Remove declaration of stpcpy - no code in BitchX uses it.
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@33 13b04d17-f746-0410-82c6-800466cd88b0
2008-05-07 08:46:59 +00:00
Kevin Easton
3de93b1dbc Far-reaching changes to make BitchX compatible with 64 bit architectures
like x86-64, where sizeof(int) != sizeof (void *).  This involves correctly
casting every function pointer from the global table to the correct
function type, which has the added benefit of allowing type-checking of
function arguments and return values.


git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@26 13b04d17-f746-0410-82c6-800466cd88b0
2008-04-30 13:57:56 +00:00
Kevin Easton
b2ec9c01bf Fix the test for GCC >= 2.7. This fixes a problem compiling on S390,
apparently.



git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@9 13b04d17-f746-0410-82c6-800466cd88b0
2008-02-28 12:42:11 +00:00
Kevin Easton
533c3dbcbf Turn on SVN keyword replacement for $Date$, $Author$, $Revision$, $Id$ for all
*.c and *.h files.


git-svn-id: svn://svn.code.sf.net/p/bitchx/code/branches/ircii-pana-1.1@3 13b04d17-f746-0410-82c6-800466cd88b0
2008-02-25 09:49:14 +00:00
Kevin Easton
28febcfea9 Initial import of the ircii-pana-1.1-final source tree.
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/tags/ircii-pana-1.1-final@1 13b04d17-f746-0410-82c6-800466cd88b0
2008-02-25 09:25:32 +00:00