Hi, With latest openembedded-core (2c134301b55892ecf3c0ae9fa4912bc827579ece) and meta-openembedded (7e9941ab0f69576542cbfeb6576750c878bdd6ca) I'm facing an issue related to readline 8.3. My test machine is raspberrypi0-wifi and I also have reproduced the same issue using qemuarm64 machine. I know that iwctl is not part of openembedded-core. However connmanctl is and according to below traces looks like the issue affects both programs. ``` root@raspberrypi0-wifi:~# iwctl Waiting for IWD to start...Segmentation fault (core dumped) iwctl root@raspberrypi0-wifi:~# connmanctl connmanctl> Segmentation fault (core dumped) connmanctl ``` Traces with gdb: ``` root@raspberrypi0-wifi:~# gdb /usr/bin/iwctl GNU gdb (GDB) 16.3 Copyright (C) 2024 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "arm-poky-linux-gnueabi". Type "show configuration" for configuration details. For bug reporting instructions, please see: <https://www.gnu.org/software/gdb/bugs/>. Find the GDB manual and other documentation resources online at: <http://www.gnu.org/software/gdb/documentation/>. For help, type "help". Type "apropos word" to search for commands related to "word"... Reading symbols from /usr/bin/iwctl... Reading symbols from /usr/bin/.debug/iwctl... (gdb) run Starting program: /usr/bin/iwctl [Thread debugging using libthread_db enabled] Using host libthread_db library "/usr/lib/libthread_db.so.1". Waiting for IWD to start... Program received signal SIGSEGV, Segmentation fault. 0xb6faed24 in update_line (old=0x440c28 "Waiting for IWD to start...", old_face=0x72 <error: Cannot access memory at address 0x72>, new=0x8f <error: Cannot access memory at address 0x8f>, new_face=0x44f838 "", current_line=current_line@entry=0, omax=27, nmax=0, inv_botlin=inv_botlin@entry=0) at ../../sources/readline-8.3/display.c:1794 warning: 1794 ../../sources/readline-8.3/display.c: No such file or directory (gdb) bt #0 0xb6faed24 in update_line (old=0x440c28 "Waiting for IWD to start...", old_face=0x72 <error: Cannot access memory at address 0x72>, new=0x8f <error: Cannot access memory at address 0x8f>, new_face=0x44f838 "", current_line=current_line@entry=0, omax=27, nmax=0, inv_botlin=inv_botlin@entry=0) at ../../sources/readline-8.3/display.c:1794 #1 0xb6fb23fc in rl_redisplay () at ../../sources/readline-8.3/display.c:1368 #2 0x0040b224 in display_enable_cmd_prompt () at ../sources/iwd-3.10/client/display.c:802 #3 0x00408ab4 in get_managed_objects_callback (message=warning: could not convert 'l_dbus_message' from the host encoding (ANSI_X3.4-1968) to UTF-32. This normally should not happen, please file a bug report. 0x455a30, user_data=<optimized out>) at ../sources/iwd-3.10/client/dbus-proxy.c:777 #4 0x0041affc in handle_method_return (dbus=dbus@entry=0x441030, message=message@entry=0x455a30) at ../sources/iwd-3.10/ell/dbus.c:204 #5 0x0041b5e8 in message_read_handler (io=<optimized out>, user_data=0x441030) at ../sources/iwd-3.10/ell/dbus.c:264 #6 0x00418394 in io_callback (fd=<optimized out>, events=1, user_data=0x440760) at ../sources/iwd-3.10/ell/io.c:105 #7 0x0041746c in l_main_iterate (timeout=<optimized out>) at ../sources/iwd-3.10/ell/main.c:461 #8 0x00417570 in l_main_run () at ../sources/iwd-3.10/ell/main.c:508 #9 l_main_run () at ../sources/iwd-3.10/ell/main.c:490 #10 0x004177f8 in l_main_run_with_signal (callback=0x403750 <signal_handler>, user_data=user_data@entry=0x0) at ../sources/iwd-3.10/ell/main.c:630 #11 0x00403540 in main (argc=1, argv=0xbefffde4) at ../sources/iwd-3.10/client/main.c:70 ``` ``` root@raspberrypi0-wifi:~# gdb /usr/bin/connmanctl GNU gdb (GDB) 16.3 Copyright (C) 2024 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "arm-poky-linux-gnueabi". Type "show configuration" for configuration details. For bug reporting instructions, please see: <https://www.gnu.org/software/gdb/bugs/>. Find the GDB manual and other documentation resources online at: <http://www.gnu.org/software/gdb/documentation/>. For help, type "help". Type "apropos word" to search for commands related to "word"... Reading symbols from /usr/bin/connmanctl... Reading symbols from /usr/bin/.debug/connmanctl... (gdb) run Starting program: /usr/bin/connmanctl [Thread debugging using libthread_db enabled] Using host libthread_db library "/usr/lib/libthread_db.so.1". connmanctl> Program received signal SIGSEGV, Segmentation fault. 0xb6e30d24 in update_line (old=0x43a2a0 "connmanctl> ", old_face=0x41d78c "\b\340A", new=0xb6fd0670 <array_types_only_reader_class> "\320\251\374\266\a", new_face=0x42b690 "", current_line=current_line@entry=0, omax=12, nmax=0, inv_botlin=inv_botlin@entry=0) at ../../sources/readline-8.3/display.c:1794 warning: 1794 ../../sources/readline-8.3/display.c: No such file or directory (gdb) bt #0 0xb6e30d24 in update_line (old=0x43a2a0 "connmanctl> ", old_face=0x41d78c "\b\340A", new=0xb6fd0670 <array_types_only_reader_class> "\320\251\374\266\a", new_face=0x42b690 "", current_line=current_line@entry=0, omax=12, nmax=0, inv_botlin=inv_botlin@entry=0) at ../../sources/readline-8.3/display.c:1794 #1 0xb6e343fc in rl_redisplay () at ../../sources/readline-8.3/display.c:1368 #2 0x0040baa0 in __connmanctl_save_rl () at ../sources/connman-1.45/client/input.c:66 #3 0x00403678 in dbus_method_reply (call=warning: could not convert 'DBusPendingCall' from the host encoding (ANSI_X3.4-1968) to UTF-32. This normally should not happen, please file a bug report. 0x41b0c8, user_data=0x41c6e8) at ../sources/connman-1.45/client/dbus_helpers.c:180 #4 0xb6fa02a4 in complete_pending_call_and_unlock (connection=0x41acc8, pending=0x41b0c8, message=<optimized out>) at ../sources/dbus-1.16.2/dbus/dbus-connection.c:2346 #5 dbus_connection_dispatch (connection=0x41acc8) at ../sources/dbus-1.16.2/dbus/dbus-connection.c:4668 #6 dbus_connection_dispatch (connection=connection@entry=0x41acc8) at ../sources/dbus-1.16.2/dbus/dbus-connection.c:4591 #7 0x0040e754 in message_dispatch (data=0x41acc8) at ../sources/connman-1.45/gdbus/mainloop.c:72 #8 0xb6eabf6c in g_main_dispatch (context=context@entry=0x41c7e0) at ../sources/glib-2.86.0/glib/gmain.c:3565 #9 0xb6eb06a4 in g_main_context_dispatch_unlocked (context=0x41c7e0) at ../sources/glib-2.86.0/glib/gmain.c:4425 #10 g_main_context_iterate_unlocked (context=0x41c7e0, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at ../sources/glib-2.86.0/glib/gmain.c:4490 #11 0xb6eb1234 in g_main_loop_run (loop=0x420d90) at ../sources/glib-2.86.0/glib/gmain.c:4695 #12 0x0040be4c in __connmanctl_input_init (argc=1, argv=0xbefffdd4) at ../sources/connman-1.45/client/input.c:266 #13 0xb6cba730 in __libc_start_call_main (main=0xb6cba730 <__libc_start_call_main+104>, main@entry=0x403408 <main>, argc=-1226842552, argc@entry=1, argv=0x403408 <main>, argv@entry=0xbefffdd4) at ../sysdeps/nptl/libc_start_call_main.h:58 #14 0xb6cba810 in __libc_start_main_impl (main=<optimized out>, argc=1, argv=0xbefffdd4, init=<optimized out>, fini=0x0, rtld_fini=0xb6fdbad4 <_dl_fini>, stack_end=0xbefffdd4) at libc-start.c:360 #15 0x00403444 in _start () at ../sysdeps/arm/start.S:105 Backtrace stopped: previous frame identical to this frame (corrupt stack?) ``` connmanctl and iwctl uses readline, so I suspect that readline 8.3 is not ok. When reverting the following commits: Revert "readline: backport a patch to fix issue that readline can't work with samba" This reverts commit e2478467b45ed2a80c32a7ee0a673555a3c98bf5. Revert "readline: 8.2.13 -> 8.3" This reverts commit 3e76f0f19c763ccf265ba9a5efe16fa9095ec76b. I don't see the issue anymore. It has to be related to readline lib but I could not identify what is. Any thoughts ? Thanks
Reverting readline may swap one set of problems for another set of problems. It was upgraded to 8.3 in July, so it has been in testing for quite a while.
Looks like https://gitlab.archlinux.org/archlinux/packaging/packages/readline/-/issues/1. The solution may be applying https://lore.kernel.org/connman/20251018212411.181909-1-jsbronder@cold-front.org/ to connman.
Sure, reverting is not an option. Maybe applying this patch https://cgit.git.savannah.gnu.org/cgit/readline.git/commit/display.c?h=devel&id=488d7edc22894d30b6de7f2d4190bf7403f63ffd to readline. I'll give a try. Looks almost this one: https://lists.gnu.org/archive/html/bug-readline/2025-07/txtmA7rksnmmi.txt from https://lists.gnu.org/archive/html/bug-readline/2025-07/msg00007.html
Hi, A feasible and working fix is here: https://patchwork.yoctoproject.org/project/oe-core/patch/20251030193525.866305-1-joaohf@gmail.com/ Thanks
Fixed by: https://git.openembedded.org/openembedded-core/commit/?id=8ce0359c4eade11b445bc227c42f7f1212a2d9c3 Thanks João !