Kevin Easton
e3750c7c1b
Remove #include <ircterm.h> from source files that don't use it
...
Update Makefile dependencies as a result of header file inclusion changes.
2018-12-11 20:30:27 +11:00
Kevin Easton
863263aa07
Make inclusion of tcl_bx.h unconditional
...
There's no need for the conditional compilation - tcl_bx.h itself has the WANT_TCL guards
necessary.
This makes generating the Makefile target dependencies easier.
2017-11-27 23:15:06 +11:00
Kevin Easton
abfe84eb5c
Use correct formats / types in snprintf() calls in tcl.c
2017-11-17 22:48:03 +11:00
Kevin Easton
bb616e0626
Change send_text() to combine command, hook and log arguments into one set of flags
...
This function is exported to modules, so it requires updating a few modules and rolling the module table version.
2017-07-09 00:08:04 +10:00
Kevin Easton
ac84793dd6
Switch from direct tcl_interp->result access to Tcl_GetStringResult() and Tcl_AppendResult()
...
This allows building against recent libtcl versions.
A fallback definition of Tcl_GetStringResult() is included so that building against libtcl 7 still works.
2017-07-01 00:47:20 +10:00
Kevin Easton
3c2028e167
Rename crypt_msg() / decrypt_msg() to sed_encrypt_msg() / sed_decrypt_msg() and move to ctcp.c
...
These functions are really specific to parsing and creating CTCP SED messages, which means they belong
in ctcp.c with the other CTCP code.
Also remove unnecessary inclusions of encrypt.h and ctcp.h.
2017-06-28 22:26:08 +10:00
Kevin Easton
0a16ab16ac
Introduce strbegins() macro and replace all open-coded instances
...
This test is done quite a bit across the tree, and the open-coded variants make it easy to have an
accidental mismatch between the length of the prefix being tested and the length actually passed to
strncmp().
This fixes an issue of that type comparing the server version against the prefix "u2.10", where the old
code used an incorrect length of 4.
2017-06-06 23:47:10 +10:00
Kevin Easton
d464bd91fb
Remove unnecessary inclusions of <numbers.h>
...
Functions display_msg() and check_sync() are only used in numbers.c, so they
can be static.
Remove inclusions of <numbers.h> from .c files that don't need it.
2016-03-24 11:21:09 +11:00
Tim Cava
3287f7775b
Convert sprintf calls to snprintf. From pvaldes.
...
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@452 13b04d17-f746-0410-82c6-800466cd88b0
2013-11-11 21:28:31 +00:00
Tim Cava
112b38ac7a
Revert the last commit. It accidentally had autogenerated files in it.
...
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@432 13b04d17-f746-0410-82c6-800466cd88b0
2013-11-07 03:00:24 +00:00
Tim Cava
276fd24258
Use snprintf rather than sprintf. From pvaldes.
...
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@431 13b04d17-f746-0410-82c6-800466cd88b0
2013-11-07 02:41:16 +00:00
Tim Cava
41dcaad142
Cleanup check_on_hook(). Use strlcat rather than strmcat. Don't
...
initialize variables unless necessary.
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@416 13b04d17-f746-0410-82c6-800466cd88b0
2013-10-26 02:54:04 +00:00
Tim Cava
9207c838f9
Use strlcpy and strlcat, rather than strmcpy and strncat, in tcl_putdcc().
...
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@360 13b04d17-f746-0410-82c6-800466cd88b0
2013-08-18 09:56:12 +00:00
Tim Cava
7af7913c98
Use strlcpy, rather than strmcpy, in tcl_putscr().
...
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@343 13b04d17-f746-0410-82c6-800466cd88b0
2013-08-17 05:21:31 +00:00
Tim Cava
172bb8c409
Use strlcpy, rather than strmcpy, in tcl_putserv().
...
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@342 13b04d17-f746-0410-82c6-800466cd88b0
2013-08-17 05:19:50 +00:00
Tim Cava
3c4acd0446
Use strlcpy, rather than strmcpy, in tcl_putloglev().
...
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@341 13b04d17-f746-0410-82c6-800466cd88b0
2013-08-17 05:16:23 +00:00
Tim Cava
5b3d5bf285
Use strlcpy, rather than strmcpy, in tcl_putcmdlog().
...
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@340 13b04d17-f746-0410-82c6-800466cd88b0
2013-08-17 05:14:29 +00:00
Tim Cava
905bceb348
Use strlcpy, rather than strmcpy, in tcl_putlog().
...
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@339 13b04d17-f746-0410-82c6-800466cd88b0
2013-08-17 05:13:15 +00:00
Tim Cava
73bf008b9f
Remove a duplicate include of dcc.h.
...
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@294 13b04d17-f746-0410-82c6-800466cd88b0
2013-07-15 06:20:49 +00:00
Kevin Easton
f7607baf45
Add tcl.c to source distribution (panasync gave his permission for this to be released).
...
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@213 13b04d17-f746-0410-82c6-800466cd88b0
2012-10-19 12:11:05 +00:00