libweston program segfaults on weston_compositor_load_backend
ppaalanen at gmail.com
Fri May 4 07:13:17 UTC 2018
On Thu, 03 May 2018 23:38:55 +0100
adlo <adloconwy at gmail.com> wrote:
> On Thu, 2018-05-03 at 14:12 +0300, Pekka Paalanen wrote:
> > what's the backtrace from gdb for that?
> Is this any help?
> #0 0x0000000000000000 in ()
> #1 0x00007ffff799c88c in weston_log (fmt=fmt at entry=0x7ffff79b6a7e
> "Loading module '%s'\n") at libweston/log.c:75
> #2 0x00007ffff79a603c in weston_load_module (name=name at entry=0x7ffff79
> b6b24 "wayland-backend.so", entrypoint=entrypoint at entry=0x7ffff79b6aae
> "weston_backend_init") at libweston/compositor.c:6375
> #3 0x00007ffff79a6264 in weston_compositor_load_backend
> (compositor=0x611090, backend=backend at entry=
> WESTON_BACKEND_WAYLAND, config_base=config_base at entry=0x7fffffffdc5
> at libweston/compositor.c:6485
> #4 0x0000000000400704 in main (argc=<optimized out>, argv=<optimized
> at ../main.c:42
Is that perhaps the very first call to weston_log()?
You need to initialize the logging mechanism before anything can call
weston_log(). Yeah, it's awkward, could probably be improved, but OTOH
one would always want all log messages going to the same place, so you
really do want to initialize the logging before any logging happens to
avoid losing messages.
The crucial call to make is weston_log_set_handler() with non-NULL
arguments before any other libweston calls.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 833 bytes
Desc: OpenPGP digital signature
More information about the wayland-devel