Sébastien Helleu
ecc7edda9e
core: optimize search of options in configuration sections
...
Since options are sorted in sections, it is faster to search from the last
option to the first one.
For configuration files with many options in a single section (like
plugins.conf), the load of configuration file is about 2 to 3x faster.
2019-10-23 19:45:06 +02:00
Sébastien Helleu
5d4220a91f
core: fix scrolling up in bare mode when switched to bare mode at the top of the buffer ( closes #899 , issue #978 )
2019-10-14 20:44:15 +02:00
Sébastien Helleu
513f5a1ee7
python: send "bytes" instead of "str" to callbacks in Python 3 when the string is not UTF-8 valid (issue #1220 , closes #1389 )
2019-10-12 22:21:48 +02:00
Sébastien Helleu
8fc8f728d4
core: add reverse of string for screen in evaluation of expressions with "revscr:"
2019-10-12 20:14:36 +02:00
Sébastien Helleu
876a0a1609
irc: add option irc.look.display_pv_warning_address ( closes #892 )
...
If the address of remote nick changes in a private buffer, a warning is
displayed.
2019-10-11 20:26:34 +02:00
Simmo Saan
116150c2fc
irc: add server option ssl_password for SSL certificate private key password ( closes #115 )
2019-10-09 21:37:41 +02:00
Sébastien Helleu
5398f5d566
irc: fix compiler warning on uninitialized variable
2019-10-09 07:17:32 +02:00
Sébastien Helleu
cbeecc0cde
core: ensure completion_item is not NULL before using it
2019-10-06 21:47:56 +02:00
Sébastien Helleu
528c769e71
core: fix crash in completion of filenames
2019-10-06 21:45:27 +02:00
Sébastien Helleu
c3b33859ae
core: fix long lines
2019-10-06 19:09:29 +02:00
Sébastien Helleu
f2551b8403
Merge remote-tracking branch 'origin/pr/630'
2019-10-06 19:07:25 +02:00
Sébastien Helleu
e6570d6e3a
core: fix line too long, add comment on argument "with_suffix"
2019-10-06 18:11:58 +02:00
Sébastien Helleu
e47002884a
core: count suffix in alignment computed for context info
2019-10-06 18:08:52 +02:00
Sébastien Helleu
c77bccba87
Merge remote-tracking branch 'origin/pr/619'
2019-10-06 18:08:17 +02:00
Sébastien Helleu
53360a7909
logger: fix write in log file if it has been deleted or renamed ( closes #123 )
2019-10-06 13:36:35 +02:00
Sébastien Helleu
587f5bf15b
irc: use path from option xfer.file.upload_path to complete filename in command "/dcc send" ( closes #60 )
2019-10-06 09:38:52 +02:00
Sébastien Helleu
6e382d26a9
core: add optional default path (evaluated) in completion "filename" (issue #60 )
2019-10-06 09:38:20 +02:00
Sébastien Helleu
88aa82d672
core: add support of modifiers in evaluation of expressions with "modifier:name,data,string" (issue #60 )
2019-10-06 09:13:35 +02:00
Sébastien Helleu
1a0ba4a9dc
api: add modifier "eval_path_home" (issue #60 )
2019-10-06 09:06:55 +02:00
Sébastien Helleu
e921b9f432
core: fix comments on modifier callback functions in plugin API
2019-10-06 08:56:12 +02:00
Sébastien Helleu
3c0bdc18f3
xfer: add option xfer.file.download_temporary_suffix with default value ".part" ( closes #1237 )
2019-10-05 18:11:39 +02:00
Sébastien Helleu
6c23f632b1
xfer: fix memory leak when a xfer is freed and when the plugin is unloaded
2019-10-05 17:49:07 +02:00
Sébastien Helleu
3e189fa60d
irc: fix typo in /help links
2019-10-04 20:44:09 +02:00
Sébastien Helleu
70fd722278
logger: add option logger.file.color_lines ( closes #528 , closes #621 )
2019-10-02 20:44:12 +02:00
Sébastien Helleu
e386965aba
api: add modifier "color_encode_ansi" (issue #528 )
2019-10-01 18:31:41 +02:00
Sébastien Helleu
90f711a965
core: add function to convert WeeChat colors to ANSI colors (issue #528 )
2019-10-01 18:31:41 +02:00
Sébastien Helleu
177fa6c528
core: add support of reverse video in ANSI color codes
2019-10-01 18:31:41 +02:00
Sébastien Helleu
daad558291
core: fix typos in comments
2019-10-01 18:31:41 +02:00
Sébastien Helleu
baf8f635ff
core: fix style in CMake files
2019-10-01 18:31:41 +02:00
Sébastien Helleu
ae38b11407
irc: add "user" in output of irc_message_parse ( closes #136 )
2019-09-27 20:52:00 +02:00
Sébastien Helleu
3f33b327b1
logger: move logger backlog functions to logger-backlog.c
2019-09-26 21:26:23 +02:00
Sébastien Helleu
3a356f109f
core: add power operator "**" in calc expressions (issue #997 )
2019-09-24 21:03:56 +02:00
Sébastien Helleu
7d795c4d53
core: fix wrong results with the unary minus in calc expressions
2019-09-24 20:49:48 +02:00
Simmo Saan
e437613acb
irc: add separate options for kick/kill message coloring ( closes #683 )
...
Add new options irc.color.message_kick and irc.color.reason_kick to be used
for coloring KICK and KILL messages.
2019-09-23 21:22:49 +02:00
Sébastien Helleu
39b6fb6137
irc: remove option irc.network.channel_encode, add server option "charset_message" ( closes #832 )
...
This new option controls which part of the IRC message is decoded/encoded to
the target charset, and the new default behavior is to decode/encode the whole
IRC message (behavior in WeeChat >= 1.3 was to decode/encode only the text by
default).
2019-09-22 20:41:00 +02:00
Sébastien Helleu
afce4804f5
guile: disable "/guile eval" as this does not (yet) work with Guile >= 2.2 (issue #1098 )
2019-09-21 14:48:09 +02:00
Sébastien Helleu
387a44f5ec
guile: add support of Guile 2.2 (issue #1098 )
2019-09-21 14:48:05 +02:00
Sébastien Helleu
e1a4612797
core: ignore color codes in ${length:xxx} and ${lengthscr:xxx}
2019-09-21 13:54:36 +02:00
Sébastien Helleu
dcfc4e8ed5
core: add "length:xxx" and "lengthscr:xxx" in evaluation of expressions
2019-09-21 07:56:21 +02:00
Sébastien Helleu
997894edc0
core: add calculation of expression in evaluation of expressions with "calc:..." (issue #997 )
2019-09-20 21:37:01 +02:00
Sébastien Helleu
5cf419dd63
core: remove extra spaces in arguments of /help uptime and /help version
2019-09-19 21:25:27 +02:00
Sébastien Helleu
85f6c5eeda
script: add options "-ol" and "-il" in command /script, display "No scripts loaded" if no scripts are loaded
2019-09-19 21:20:55 +02:00
Tobias Stoeckmann
f7b84fcc67
Fixed segfault during excessive evaluation.
...
It is possible to trigger a segmentation fault while processing
an evaluation of repeating string. On a Linux 64 bit system,
enter this (or adjust arguments for 32 bit accordingly):
/eval -n ${repeat:1073741824,----}
It will overflow an integer calculation because int instead of
size_t is used. Proper check of int limitations fixes this issue.
I haven't changed this specific piece of code to size_t because it
would crash in other parts of the code tree instead. For now, int
is a limitating factor when it comes to strings (and should be
enough for sane use cases).
Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
2019-09-17 21:26:52 +02:00
Sébastien Helleu
63a05d72d9
buflist: fix extra spaces between buffers when conditions are used to hide buffers ( closes #1403 )
...
This is a regression introduced in version 2.6 by commit
bf21ca072d
.
2019-09-17 21:21:28 +02:00
Sébastien Helleu
e8be4f62af
core: mention possible background color in /help weechat.look.nick_color_force
2019-09-16 20:58:12 +02:00
Sébastien Helleu
bff40e4c26
core: display an error on missing dependency in CMake ( closes #916 , closes #956 )
2019-09-15 07:49:03 +02:00
Sébastien Helleu
1beebdf01e
core: fix compilation with autotools on FreeBSD 12.0
2019-08-31 14:18:55 +02:00
Sébastien Helleu
8bb4549494
core: fix compilation of Python plugin on FreeBSD 12.0 ( closes #1398 )
2019-08-31 14:13:58 +02:00
Sébastien Helleu
68d6f1b415
api: add infos "term_colors" and "term_color_pairs"
2019-08-25 19:10:32 +02:00
Sébastien Helleu
f0685dd1b1
ruby: remove unused variable "ruby_hide_errors"
2019-08-25 07:14:42 +02:00
Sébastien Helleu
bad8db720e
irc: fix parsing of message 346, 348 and 728 when there is a colon before the timestamp (issue #1396 )
...
IRC Messages:
- 346: invite list
- 348: exception list
- 728: quiet list
2019-08-24 07:19:01 +02:00
Sébastien Helleu
61c5d08320
fset: add filters "h=xxx" and "he=xxx" to filter options by description (translated or in English)
2019-08-24 07:13:34 +02:00
iwalkalone
1e7232b8c2
irc: fix parsing of message 367 (banlist) when there is a colon before the timestamp ( closes #1396 )
2019-08-21 08:21:07 +02:00
Sébastien Helleu
608ec9f483
core: add values djb2_32 and sum_32 for option weechat.look.nick_color_hash (issue #1394 )
2019-08-20 21:20:33 +02:00
Sébastien Helleu
21dca71ee0
ruby: fix compilation with Ruby < 2.3
2019-08-20 07:57:01 +02:00
Sébastien Helleu
7f62985f89
core: use fixed-width integer for computing hashtable DJB2 key hash ( closes #1394 )
2019-08-19 23:29:22 +02:00
Sébastien Helleu
80f103b68a
core: use fixed-width integer for computing nick hash (issue #1394 )
2019-08-19 23:27:11 +02:00
Sébastien Helleu
156d855787
ruby: fix conversion of big integers on 32bit architecture ( closes #1395 )
2019-08-19 23:21:12 +02:00
Sébastien Helleu
bf21ca072d
buflist: use extra variables in option buflist.look.display_conditions ( closes #1393 )
2019-08-17 08:57:40 +02:00
Sébastien Helleu
a3e8163f37
Revert "buflist: mention variables available for option buflist.look.display_conditions in its help and in /help buflist ( closes #1393 )"
...
This reverts commit 39e5b0574c
.
2019-08-17 08:43:22 +02:00
Sébastien Helleu
39e5b0574c
buflist: mention variables available for option buflist.look.display_conditions in its help and in /help buflist ( closes #1393 )
2019-08-17 08:17:11 +02:00
Sébastien Helleu
c411ee475a
core: create or update option weechat.notify.xxx when function buffer_set is called with "notify" property ( closes #1390 )
2019-08-10 17:48:34 +02:00
Andrew Potter
0957231d30
api: add function list_user_data (issue #666 )
2019-08-10 12:55:43 +02:00
Sébastien Helleu
5f1b895f27
irc: replace calls to strcpy and strcat with a call to snprintf
2019-08-10 11:20:43 +02:00
Sébastien Helleu
dfcbb6b058
irc: rename variable vars_replaced to command2, remove fallback on *ptr_command
2019-08-10 11:16:21 +02:00
Sébastien Helleu
dd133af522
Merge remote-tracking branch 'origin/pr/615'
2019-08-10 11:12:13 +02:00
Sébastien Helleu
210e864899
irc: fix memory leak when removing a server
2019-08-05 20:58:24 +02:00
Sébastien Helleu
b6cc5ef70f
irc: fix length of user/nick/host in split of messages ( closes #1387 )
2019-08-04 16:39:18 +02:00
Sébastien Helleu
0bf5a5ae9c
irc: add variables "user_max_length" and "host_max_length" in server structure (issue #1387 )
2019-08-04 14:39:58 +02:00
Sébastien Helleu
4fa62a83f1
tests: add unit tests on IRC functions irc_message_split* (issue #1387 )
2019-08-04 14:39:58 +02:00
Sébastien Helleu
fbc022a77a
core: return NULL immediately if string is NULL in function hook_modifier_exec
2019-08-04 13:30:53 +02:00
Sébastien Helleu
c46255b1d0
tests: add unit tests on IRC functions irc_message_parse and irc_message_parse_to_hashtable
2019-08-03 13:57:50 +02:00
Sébastien Helleu
478ca22054
irc: return NULL in function irc_message_get_address_from_host if the received host is NULL
2019-08-03 10:53:17 +02:00
Sébastien Helleu
f8b8669d2e
Merge pull request #1384 from l2dy/memory
...
core: fix memory leak in case of error
2019-07-31 22:51:12 +02:00
Eli Schwartz
ad7d16a5b3
build: use pkg-config to properly link python
...
fixes incorrect (non)detection of libpython3.Ym.so due to PEP 3149 since
python's officially exported build flags know how to correctly link to
python.
2019-07-31 20:45:59 +02:00
Sébastien Helleu
015ec85f10
core: add some missing default keys in /help cursor
2019-07-29 22:49:29 +02:00
Zero King
acbf021330
core: fix memory leak in case of error
2019-07-27 18:51:29 +00:00
Sébastien Helleu
5eeb98e40c
buflist: use existing variable buflist_hdata_buffer to check buffer pointers in infolist "buflist"
2019-07-13 22:16:25 +02:00
Sébastien Helleu
643376fc1d
core: update translations (issue #1375 )
2019-07-11 07:30:01 +02:00
Sébastien Helleu
ccaf99ff40
buflist: check validity of buffer pointers in info "buflist" (issue #1375 )
2019-07-11 07:29:54 +02:00
Simmo Saan
0fdf2c13a5
buflist: add infolist "buflist" (issue #1375 )
2019-07-11 07:29:46 +02:00
Sébastien Helleu
fd592c2323
irc: quote NICK command argument sent to the server only if there's a ":" in the nick ( closes #1376 , issue #1319 )
2019-07-11 07:08:36 +02:00
Sébastien Helleu
162ca1fade
irc: split function irc_ignore_check into three functions
2019-07-10 19:19:35 +02:00
Sébastien Helleu
15ce4b2be5
irc: return all arguments in the PONG response to a PING ( closes #1369 )
2019-07-04 18:48:46 +02:00
Sébastien Helleu
d540ea91ae
Merge remote-tracking branch 'origin/pr/1345'
2019-06-28 20:43:21 +02:00
Sébastien Helleu
33ee803609
core: send command line parameter to plugins only if the name starts with the plugin name followed by a colon
2019-06-26 21:13:36 +02:00
Sébastien Helleu
1d6714e428
core: auto disable upgrade process (command line option "--upgrade") if the file weechat.upgrade is not found
2019-06-24 21:35:37 +02:00
Sébastien Helleu
b0ad684f6b
irc: fix help of /connect command: the server is optional
2019-06-22 08:42:38 +02:00
Sébastien Helleu
f15a24b2ec
core: add option "close" in command /window ( closes #853 )
2019-06-17 21:08:07 +02:00
Sébastien Helleu
087d4c7af3
core: add Curl options for versions 7.53.0 to 7.63.0
2019-06-16 22:28:08 +02:00
Sébastien Helleu
fe90a5ed4e
core: replace newlines by spaces in argument "completion" of function hook_command ( closes #538 )
2019-06-16 08:14:24 +02:00
Sébastien Helleu
60c61c3962
irc: disable server reconnection when the server buffer is closed ( closes #236 )
2019-06-15 22:46:14 +02:00
Sébastien Helleu
0d9b7ec954
irc: strip spaces at beginning/end of addresses in server option "addresses" ( closes #195 )
2019-06-15 20:50:48 +02:00
Sébastien Helleu
9178156354
api: add argument "strip_items" in function string_split
2019-06-15 20:47:14 +02:00
Sébastien Helleu
866a29c7e6
core: check that string pointer is not NULL in function "string_shared_get"
2019-06-15 17:21:06 +02:00
Sébastien Helleu
95cbf3a48b
irc: remove capability from cap_list when a client capability is disabled (issue #151 )
2019-06-15 08:56:48 +02:00
Sébastien Helleu
b6c304ac87
irc: fix display of enabled/disabled client capabilities received in command CAP ACK ( closes #151 )
2019-06-15 08:14:22 +02:00
Sébastien Helleu
04fd587fff
exec: evaluate option exec.command.shell, change default value to "${env:SHELL}" ( closes #1356 )
2019-06-12 18:29:07 +02:00
jesopo
4ea193c981
alias: remove default aliases /AME and /AMSG
2019-06-07 21:35:15 +02:00
Sébastien Helleu
7aa82db471
core: replace char "," by "~" in color codes to separate foreground from background ( closes #1264 )
2019-06-07 21:29:05 +02:00
Sébastien Helleu
22895f3f5e
relay: set socket option SO_KEEPALIVE only for TCP sockets when creating the socket (issue #733 )
2019-06-04 22:59:42 +02:00
Sébastien Helleu
479d234ced
relay: set socket option SO_REUSEADDR only for TCP sockets when creating the socket (issue #733 )
2019-06-04 22:54:00 +02:00
Sébastien Helleu
86d9cb1e41
relay: set socket option SO_REUSEADDR only for TCP sockets (issue #733 )
2019-06-04 22:45:54 +02:00
Sébastien Helleu
b4dadd6d98
relay: add UNIX domain socket completion for command /relay add (issue #733 )
2019-06-04 22:29:18 +02:00
Sébastien Helleu
22e6777aed
relay: fix crash when deleting a relay (issue #733 )
2019-06-04 22:19:39 +02:00
Sébastien Helleu
66011b4bee
relay: fix truncated path when the unix socket path is longer than the authorized one (issue #733 )
2019-06-04 22:19:31 +02:00
Sébastien Helleu
917b2ddf69
spell: add a warning if aspell.conf is still present (on first spell load)
2019-06-04 20:56:05 +02:00
Sébastien Helleu
34adcde2ff
irc: add extra check on argument "nick" in functions "irc_nick_set_*"
2019-05-14 07:26:48 +02:00
Sébastien Helleu
f6d6f7bac5
irc: fix crash when the nick in incoming message is not found in channel
2019-05-14 07:25:04 +02:00
Sébastien Helleu
90610c55c8
relay: remove useless condition
...
This fixes a compilation warning on FreeBSD.
2019-05-13 22:08:35 +02:00
Sébastien Helleu
ec5aca81e7
relay: set address to "local" if not known
2019-05-13 21:57:23 +02:00
Sébastien Helleu
9ed89beaa0
core: update translations
2019-05-13 21:43:11 +02:00
Sébastien Helleu
8121747e7b
relay: rename variables in function relay_config_check_path_length
2019-05-13 20:50:13 +02:00
Simmo Saan
980d26956f
gui: fix wide ncurses header on FreeBSD (issue #1343 )
2019-05-13 13:48:39 +00:00
Sébastien Helleu
6f3e563f8b
relay: fix comment
2019-05-12 22:57:25 +02:00
Sébastien Helleu
d1577b34da
relay: set mode 700 on the unix socket file (only the owner can use it)
2019-05-12 22:27:43 +02:00
Sébastien Helleu
ef1fcbd183
relay: do not overwrite a file if it's not a socket, display an error when the socket can not be created
2019-05-12 22:18:42 +02:00
Sébastien Helleu
585eb337e8
relay: evaluate path of unix socket relay
2019-05-12 21:53:23 +02:00
Sébastien Helleu
b228ccdfc3
relay: rename function relay_config_check_path_len to relay_config_check_path_length
2019-05-12 21:39:22 +02:00
Sébastien Helleu
ade52cdc7d
relay: fix update of port/path variables in relay server when options relay.port.* and relay.path.* are changed with /set
2019-05-12 21:39:22 +02:00
Sébastien Helleu
eacc08f2e1
relay: fix section used when the unix relay does not start with "unix."
2019-05-12 21:39:22 +02:00
Sébastien Helleu
f273487688
relay: add unix relay format in /help relay
2019-05-12 21:39:22 +02:00
Sébastien Helleu
170c523c84
relay: remove extra newline at the end of /help relay
2019-05-12 21:39:22 +02:00
Sébastien Helleu
c4230ecece
relay: remove local variable ptr_server from function relay_config_check_path_cb (not needed)
2019-05-12 21:39:22 +02:00
Sébastien Helleu
c1af2702b8
relay: improve message displayed on a new client
2019-05-12 21:39:22 +02:00
Sébastien Helleu
78fda01dd5
relay: improve message displayed when the relay is removed
2019-05-12 21:39:22 +02:00
Sébastien Helleu
9d04bc5801
relay: improve message displayed when the relay is added
2019-05-12 21:39:22 +02:00
Sébastien Helleu
abe85999d8
relay: rename function relay_config_create_option_port to relay_config_create_option_port_path
2019-05-12 21:39:22 +02:00
Sébastien Helleu
df3848e1f0
relay: fix code style
2019-05-12 21:39:22 +02:00
Sébastien Helleu
c78fb8dc7c
relay: rename variable "un" to "unix_socket"
2019-05-12 18:52:22 +02:00
Ryan Farley
ffefd1b785
relay: add UNIX socket support ( closes #733 )
2019-05-12 18:51:13 +02:00
Sébastien Helleu
a24817b141
irc: rename server variable "nick_host" to "host"
2019-05-12 07:46:01 +02:00
Sébastien Helleu
26ba04b454
irc: set buffer local variable "nick_host" when a channel buffer is opened
2019-05-10 22:25:56 +02:00
Sébastien Helleu
35237c8088
irc: add bar items "irc_nick", "irc_host" and "irc_nick_host"
2019-05-10 22:00:33 +02:00
Sébastien Helleu
06aa7034fb
irc: add variable "nick_host" in server structure
2019-05-10 21:59:31 +02:00
Sébastien Helleu
2073408b86
irc: fix parsing of MODE command when there are colons after the first mode argument ( closes #1296 )
2019-05-10 19:29:58 +02:00
Simmo Saan
5910bcf3c8
gui: fix wbkgrndset for non-wide ncurses by fallback to wbkgdset (issue #1343 )
...
cchar_t, setcchar and wbkgrndset are actually widec ncurses features,
not ext-colors features, but NCURSES_WIDECHAR doesn't accurately reflect
their existence so NCURSES_EXT_COLORS is used instead.
2019-05-04 14:31:11 +03:00
Simmo Saan
c7b242ffd9
gui: readd color buffer table zero padding and dashes (issue #1343 )
2019-05-02 21:16:57 +03:00
Simmo Saan
bf1462d7a1
gui: change command line option "-c" color pairs table to match (issue #1343 )
2019-05-02 21:06:42 +03:00
Simmo Saan
f5f6cf028c
gui: change color buffer pairs table to only show allocated pairs (issue #1343 )
2019-05-02 19:30:22 +03:00
Simmo Saan
d392b406c5
gui: increase ncurses color pair limit from 255 to 32767 (issue #1343 )
2019-05-02 19:30:22 +03:00
Simmo Saan
08719963de
gui: replace ncurses COLOR_PAIR attribute usage with special functions (issue #1343 )
2019-05-02 19:30:22 +03:00
Ryan Farley
8df3ad3d26
cmake: allow custom libdir ( fix #1341 )
...
Allows for custom LIBDIR to specified with cmake builds. WEECHAT_LIBDIR
is used for a custom Weechat directory, or set from LIBDIR (as LIBDIR
used to be set).
2019-04-25 16:53:55 -05:00
Sébastien Helleu
1582d923e6
core: use getopt to parse command line arguments
...
Multiple options can now be given in a single flag, for example:
weechat -ast
Following formats were allowed for command line argument with a value:
weechat -d /tmp/weechat
weechat --dir /tmp/weechat
Now these extra formats are supported as well:
weechat -d/tmp/weechat
weechat --dir=/tmp/weechat
2019-04-14 13:35:47 +02:00
Sébastien Helleu
4063abc86b
core: bump API version
...
This is required after changes on functions hook_info and info_get.
2019-04-13 20:48:42 +02:00
Sébastien Helleu
ebf38f142e
core: merge functions gui_line_prefix_is_same_nick_as_{previous|next} (issue #931 )
2019-04-13 20:46:05 +02:00
Sébastien Helleu
573377e2d9
core: fix /help weechat.look.buffer_time_same
2019-04-13 20:38:19 +02:00
Adrian Bjugård
0b5bff9ef5
core: add option weechat.look.prefix_same_nick_middle ( closes #930 , closes #931 )
2019-04-13 20:36:41 +02:00
Simmo Saan
97e9046918
core: add option weechat.look.buffer_time_same ( closes #1127 )
2019-04-13 14:45:53 +02:00
Sébastien Helleu
30768d4d24
trigger: add hook "info_hashtable"
2019-04-13 13:53:16 +02:00