aboutsummaryrefslogtreecommitdiffstats
path: root/src/bytecode.c
diff options
context:
space:
mode:
authorF. Jason Park2025-07-17 23:34:05 -0700
committerF. Jason Park2025-07-27 19:57:28 -0700
commit2f5fe1a48eb26c4885657e2634d8fe9190ab659b (patch)
tree5ca2a720ba78102a0a566199b6e9aa0ca22bc917 /src/bytecode.c
parent068b324d999b36aa29a3ed861b62ce053b506733 (diff)
downloademacs-2f5fe1a48eb26c4885657e2634d8fe9190ab659b.tar.gz
emacs-2f5fe1a48eb26c4885657e2634d8fe9190ab659b.zip
Cancel ERC autojoin timer in the server buffer
* lisp/erc/erc-join.el (erc-autojoin-channels-delayed): Only cancel `erc--autojoin-timer' in the server buffer in which it's local. After Emacs 28 brought commit fc66ec33226aeed0b745356363ed952c8ff1f7fd "Prefer defvar-local in erc", customizing `erc-autojoin-timing' to `ident' led to ERC emitting redundant JOINs before `erc-autojoin--join' was factored out. Additionally, don't bother binding options around the call to `erc-autojoin-channels' to shape its behavior, preferring instead to call the internal workhorse function directly. Ever since bug#5521 introduced those options, the logic in `erc-autojoin-channels' has ignored `erc-autojoin-delay' anyway, so long as `erc-autojoin-timing' isn't `ident'. This change may break third party advice. (erc-autojoin-after-ident): Restore code to cancel timer. It was erroneously deleted in 959fbcf34b5dd04e1b4bf87c0b73afd784a41f7f "favor network identities in erc-join". * test/lisp/erc/erc-join-tests.el: Require erc-tests-common atop file so tests can take advantage of common utilities. (erc-autojoin-channels--connect): Replace with a function and three separate tests. (erc-join-tests--autojoin-channels-connect): New function. (erc-autojoin-channels/server, erc-autojoin-channels/network) (erc-autojoin-channels/nomatch): New tests. (erc-autojoin-channels--delay): Replace with a function and three separate tests. Remove guard to skip test on Solaris. (erc-join-tests--autojoin-channels-ident): New function. (erc-autojoin-channels-delayed/server) (erc-autojoin-channels-delayed/network) (erc-autojoin-channels-delayed/nomatch): New tests. (erc-autojoin-channels--ident): Replace with function and two separate tests. (erc-join-tests--autojoin-after-ident): New function. (erc-autojoin-after-ident/server) (erc-autojoin-after-ident/network): New tests. (erc-join-tests--autojoin-add--common) (erc-join-tests--autojoin-add): Rename former to latter. (erc-autojoin-add--network) (erc-autojoin-add--network-extended-syntax) (erc-autojoin-add--network-id): Adjust arguments to fixture. (erc-autojoin-add--server): Use common utils. (erc-join-tests--autojoin-remove--common) (erc-join-tests--autojoin-remove): Rename former to latter. (erc-autojoin-remove--network) (erc-autojoin-remove--network-id): Adjust args for fixture. (erc-autojoin-remove--server): Use common utils. * test/lisp/erc/erc-scenarios-join-timing.el: New file. * test/lisp/erc/resources/erc-scenarios-common.el (erc-scenarios-common--run-in-term): In subprocess, don't use failure tally as exit status unless body form succeeds. * test/lisp/erc/resources/erc-tests-common.el (erc-tests-common-init-server-proc): Use `make-process' instead of `start-process'. (erc-tests-common-make-server-buf): Use `erc-server-current-nick' to create the `erc-networks--id' as a `erc-networks--id-qualifying' instance, which is more realistic than a "fixed" variant. * test/lisp/erc/resources/join/timing/connect-both.eld: New file. * test/lisp/erc/resources/join/timing/ident-both.eld: New file. (Bug#79017)
Diffstat (limited to 'src/bytecode.c')
0 files changed, 0 insertions, 0 deletions