[LBBS-156] mod_irc_bouncer: Occasional deadlocks when running test_irc_bouncer
2026-04-05T16:48:38.9996191Z ==60642== Process terminating with default action of signal 6 (SIGABRT): dumping core
2026-04-05T16:48:38.9997055Z ==60642== at 0x4F1B9FC: __pthread_kill_implementation (pthread_kill.c:44)
2026-04-05T16:48:38.9997862Z ==60642== by 0x4F1B9FC: __pthread_kill_internal (pthread_kill.c:78)
2026-04-05T16:48:38.9998687Z ==60642== by 0x4F1B9FC: pthread_kill@@GLIBC_2.34 (pthread_kill.c:89)
2026-04-05T16:48:38.9999319Z ==60642== by 0x4EC7475: raise (raise.c:26)
2026-04-05T16:48:38.9999805Z ==60642== by 0x4EAD7F2: abort (abort.c:79)
2026-04-05T16:48:39.0000368Z ==60642== by 0x11D83A: __bbs_assert_fatal (backtrace.c:303)
2026-04-05T16:48:39.0001112Z ==60642== by 0x12ED3E: __bbs_assert (bbs.h:437)
2026-04-05T16:48:39.0001657Z ==60642== by 0x12ED3E: mutex_deadlock_check (lock.c:206)
2026-04-05T16:48:39.0002210Z ==60642== by 0x12ED3E: __bbs_mutex_lock (lock.c:323)
2026-04-05T16:48:39.0002780Z ==60642== by 0x64C6AA1: privmsg_cb (mod_irc_bouncer.c:801)
2026-04-05T16:48:39.0003392Z ==60642== by 0x5C3882C: _programmatic_privmsg (net_irc.c:646)
2026-04-05T16:48:39.0004019Z ==60642== by 0x5C3ADB9: programmatic_privmsg (net_irc.c:666)
2026-04-05T16:48:39.0004625Z ==60642== by 0x5C3ADB9: programmatic_privmsg (net_irc.c:655)
2026-04-05T16:48:39.0005187Z ==60642== by 0x5C3ADB9: privmsg (net_irc.c:1744)
2026-04-05T16:48:39.0005712Z ==60642== by 0x5C41D3F: handle_privmsg (net_irc.c:1862)
2026-04-05T16:48:39.0006262Z ==60642== by 0x5C41D3F: handle_client (net_irc.c:4121)
2026-04-05T16:48:39.0006790Z ==60642== by 0x5C45FDD: irc_handler (net_irc.c:4650)
2026-04-05T16:48:39.0007316Z ==60642== by 0x5C45FDD: __irc_handler (net_irc.c:4659)
2026-04-05T16:48:39.0007817Z ==60642== by 0x15C344: thread_run (thread.c:512)
2026-04-05T16:48:39.0008351Z ==60642== by 0x4F19AC2: start_thread (pthread_create.c:442)
Thread 1 (Thread 0x7faee1b826c0 (LWP 2374996)):
#4 0x0000564f309dd847 in __bbs_assert_fatal (condition_str=<optimized out>, file=<optimized out>, line=<optimized out>, function=<optimized out>) at backtrace.c:303
#5 0x0000564f309ee5b5 in __bbs_assert (condition=<optimized out>, condition_str=<optimized out>, file=<optimized out>, line=<optimized out>, function=<optimized out>) at ../include/bbs.h:437
#6 __bbs_mutex_lock (t=t@entry=0x564f3cbd0328, filename=filename@entry=0x7faee5057843 "mod_irc_bouncer.c", lineno=lineno@entry=813, func=func@entry=0x7faee5057f28 <__func__.24> "privmsg_cb", name=name@entry=0x7faee5057a35 "&bu->lock") at lock.c:384
#7 0x00007faee50541da in privmsg_cb (hostmask=0x7faee1b81710 "testuser2!testuser2@node/2", sender=<optimized out>, recipient=0x7faee1b81b68 "testuser", msg=0x7faee1b81b72 "Are you around?") at mod_irc_bouncer.c:813
#8 0x00007faee3c1118d in _programmatic_privmsg (hostmask=hostmask@entry=0x7faee1b81710 "testuser2!testuser2@node/2", username=0x7faed0002050 "testuser2", recipient=recipient@entry=0x7faee1b81b68 "testuser", msg=msg@entry=0x7faee1b81b72 "Are you around?") at net_irc.c:645
#9 0x00007faee3c13822 in programmatic_privmsg (user=0x7faed0000bb0, recipient=0x7faee1b81b68 "testuser", msg=0x7faee1b81b72 "Are you around?") at net_irc.c:665
#10 programmatic_privmsg (user=0x7faed0000bb0, recipient=0x7faee1b81b68 "testuser", msg=0x7faee1b81b72 "Are you around?") at net_irc.c:654
#11 privmsg (user=user@entry=0x7faed0000bb0, channame=0x7faee1b81b68 "testuser", notice=notice@entry=0, message=0x7faee1b81b72 "Are you around?") at net_irc.c:1735
#12 0x00007faee3c1a61e in handle_privmsg (user=<optimized out>, s=<optimized out>, notice=0) at net_irc.c:1853
#13 handle_client (user=user@entry=0x7faed0000bb0) at net_irc.c:4112
buf = "PRIVMSG\000testuser\000:Are you around?\000\000\000yMgBQQHNzdzByRA==", '\000' <repeats 204 times>...
#14 0x00007faee3c1d084 in irc_handler (node=0x7faed8001290, secure=0) at net_irc.c:4641
#15 __irc_handler (varg=varg@entry=0x7faed8001290) at net_irc.c:4650
node = 0x7faed8001290Comments
You must be logged in to leave a comment.
4/9/2026 6:35 PM — InterLinked
Autoresolved by code commit on GitHub:
mod_irc_bouncer: Fix locking and logging issues.
https://github.com/InterLinked1/lbbs/commit/ffe4c5670822089be03aecfcbacc062cf21e68cd