Created attachment 242273 [details] Patch to keep link closed after USR2 signal until USR1 is received. Since sometime around end of 2022 mpd5 after being sent a USR2 signal to close the first link, automatically brings the link back up again without waiting to receive a USR1 signal. Probably a side effect of patch-redial.
Created attachment 242276 [details] proposed fix Please test this patch instead. Download it to /usr/ports/net/mpd5/patch-sigusr then rebuild, reinstall and restart mpd5.
(In reply to Eugene Grosbein from comment #1) Saved your patch to /usr/ports/net/mpd5/files/patch-sigusr, rebuilt, reinstalled and restarted mpd5, then tested bringing the link down then up again using USR2 and USR1 signals. Works for me, after SIGUSR2, link stays down until receipt of SIGUSR1.
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=a022a2a4c48c341256a1d4f53b2be12ac31239c7 commit a022a2a4c48c341256a1d4f53b2be12ac31239c7 Author: Eugene Grosbein <eugen@FreeBSD.org> AuthorDate: 2023-05-20 11:15:11 +0000 Commit: Eugene Grosbein <eugen@FreeBSD.org> CommitDate: 2023-05-20 11:22:39 +0000 net/mpd5: new small feature and bugfix - Import r2539 from upstream: introduce new interface description conversion specification %s for last description change time, in unixtime (seconds). - Unbreak SIGUSR1/SIGUSR2 mechanics to open/close first link broken in mpd5-5.9_10 (*) PR: 271508 (*) net/mpd5/Makefile | 2 +- net/mpd5/files/patch-ifdescr (new) | 35 +++++++++++++++ net/mpd5/files/patch-redial | 92 ++++++++++++++++++++++++++++++++------ 3 files changed, 114 insertions(+), 15 deletions(-)
Thank you very much for the report! Remove patch-sigusr and update your ports tree to get new revision mpd5-5.9_16 containing the fix.
(In reply to Eugene Grosbein from comment #4) Update just came through, removed patch-sigusr and reinstalled mpd5. Thank you very much.