On Mon, Apr 14, 2014 at 10:06:44AM -0400, Chet Ramey wrote: > On 4/13/14, 6:46 PM, Thomas Klausner wrote: > > Hi! > > > > Since a couple of weeks ago, gnucash as installed by pkgsrc on > > NetBSD-6.99.40/amd64 doesn't start in the background any longer for > > me. > > > > It looks like this (in zsh): > > It looks like gnucash, when linked with readline, attempts to write to the > controlling terminal and gets a SIGTTOU. > > >> gnucash & > > [1] 8065 > >> > > [1] + suspended (tty output) gnucash > >> fg > > [1] + continued gnucash > > Found Finance::Quote version 1.18 > > (runs) > > And it appears that the above message about `Quote version 1.18' is what it > tries to write. > > I suppose it could be readline reacting to the SIGTTOU and calling the > signal hook, but I doubt that python has a signal hook assigned. If > there's no signal hook, readline just passes the signal through to the > calling application. In the case of SIGTTOU, unless the calling > application is ignoring it, the process will be stopped. > > It might be useful to get a stack traceback from the gnucash process > when it gets a SIGTTOU.
I've installed a signal handler catching SIGTTOU and calling abort() in the gnucash binary. Here's the backtrace: (gdb) bt #0 0x00007f7fdcb0e12a in _lwp_kill () from /usr/lib/libc.so.12 #1 0x00007f7fdcb0ddb5 in abort () at /archive/foreign/src/lib/libc/stdlib/abort.c:74 #2 0x0000000000405ea0 in debug_step (signal=22) at gnucash-bin.c:565 #3 <signal handler called> #4 0x00007f7fdcad1b08 in ioctl () from /usr/lib/libc.so.12 #5 0x00007f7fc821a0fa in set_winsize () from /usr/pkg/lib/libreadline.so.6 #6 0x00007f7fc821a351 in rltty_set_default_bindings () from /usr/pkg/lib/libreadline.so.6 #7 0x00007f7fc8216599 in rl_initialize () from /usr/pkg/lib/libreadline.so.6 #8 0x00007f7fc8603656 in initreadline () from /usr/pkg/lib/python2.7/lib-dynload/readline.so #9 0x00007f7fd5edefc3 in _PyImport_LoadDynamicModule () from /usr/pkg/lib/libpython2.7.so.1.0 #10 0x00007f7fd5edd3e8 in import_submodule () from /usr/pkg/lib/libpython2.7.so.1.0 #11 0x00007f7fd5edd695 in load_next () from /usr/pkg/lib/libpython2.7.so.1.0 #12 0x00007f7fd5edde92 in PyImport_ImportModuleLevel () from /usr/pkg/lib/libpython2.7.so.1.0 #13 0x00007f7fd5ec648b in builtin___import__ () from /usr/pkg/lib/libpython2.7.so.1.0 #14 0x00007f7fd5e46a98 in PyObject_Call () from /usr/pkg/lib/libpython2.7.so.1.0 #15 0x00007f7fd5ec7d40 in PyEval_CallObjectWithKeywords () from /usr/pkg/lib/libpython2.7.so.1.0 #16 0x00007f7fd5ecae83 in PyEval_EvalFrameEx () from /usr/pkg/lib/libpython2.7.so.1.0 #17 0x00007f7fd5ecde47 in PyEval_EvalCodeEx () from /usr/pkg/lib/libpython2.7.so.1.0 #18 0x00007f7fd5ecdef2 in PyEval_EvalCode () from /usr/pkg/lib/libpython2.7.so.1.0 #19 0x00007f7fd5edc6a3 in PyImport_ExecCodeModuleEx () from /usr/pkg/lib/libpython2.7.so.1.0 #20 0x00007f7fd5edc8d5 in load_source_module () from /usr/pkg/lib/libpython2.7.so.1.0 #21 0x00007f7fd5edd3e8 in import_submodule () from /usr/pkg/lib/libpython2.7.so.1.0 #22 0x00007f7fd5edd60a in load_next () from /usr/pkg/lib/libpython2.7.so.1.0 #23 0x00007f7fd5eddec7 in PyImport_ImportModuleLevel () from /usr/pkg/lib/libpython2.7.so.1.0 #24 0x00007f7fd5ec648b in builtin___import__ () from /usr/pkg/lib/libpython2.7.so.1.0 #25 0x00007f7fd5e46a98 in PyObject_Call () from /usr/pkg/lib/libpython2.7.so.1.0 #26 0x00007f7fd5ec7d40 in PyEval_CallObjectWithKeywords () from /usr/pkg/lib/libpython2.7.so.1.0 #27 0x00007f7fd5ecae83 in PyEval_EvalFrameEx () from /usr/pkg/lib/libpython2.7.so.1.0 #28 0x00007f7fd5ecde47 in PyEval_EvalCodeEx () from /usr/pkg/lib/libpython2.7.so.1.0 #29 0x00007f7fd5ecdef2 in PyEval_EvalCode () from /usr/pkg/lib/libpython2.7.so.1.0 #30 0x00007f7fd5ee4d6f in run_mod () from /usr/pkg/lib/libpython2.7.so.1.0 #31 0x00007f7fd5ee5cd7 in PyRun_FileExFlags () from /usr/pkg/lib/libpython2.7.so.1.0 #32 0x00007f7fd5ee6cdd in PyRun_SimpleFileExFlags () from /usr/pkg/lib/libpython2.7.so.1.0 #33 0x00007f7fd6a00fac in libgncmod_python_gnc_module_init () from /usr/pkg/lib/gnucash/libgncmod-python.so #34 0x00007f7fe9203001 in gnc_module_load_common () from /usr/pkg/lib/libgnc-module.so.0 #35 0x0000000000405ba4 in load_gnucash_modules () at gnucash-bin.c:477 #36 0x0000000000405efd in inner_main (closure=0x0, argc=1, argv=0x7f7fffffd568) at gnucash-bin.c:584 #37 0x00007f7fe865fbf3 in invoke_main_func () from /usr/pkg/lib/libguile.so.17 #38 0x00007f7fe863b6da in c_body () from /usr/pkg/lib/libguile.so.17 #39 0x00007f7fe8696923 in scm_c_catch () from /usr/pkg/lib/libguile.so.17 #40 0x00007f7fe863bbdc in scm_i_with_continuation_barrier () from /usr/pkg/lib/libguile.so.17 #41 0x00007f7fe863bc60 in scm_c_with_continuation_barrier () from /usr/pkg/lib/libguile.so.17 #42 0x00007f7fe8695148 in scm_i_with_guile_and_parent () from /usr/pkg/lib/libguile.so.17 #43 0x00007f7fe865fd10 in scm_boot_guile () from /usr/pkg/lib/libguile.so.17 #44 0x0000000000406458 in main (argc=1, argv=0x7f7fffffd568) at gnucash-bin.c:780 What does this tell you? Thomas _______________________________________________ Bug-readline mailing list [email protected] https://lists.gnu.org/mailman/listinfo/bug-readline
