Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Segfault while trying to interact with UI when file is loading #136

Open
myrrc opened this issue Apr 26, 2024 · 4 comments
Open

Segfault while trying to interact with UI when file is loading #136

myrrc opened this issue Apr 26, 2024 · 4 comments
Assignees

Comments

@myrrc
Copy link

myrrc commented Apr 26, 2024

Sfizz version: latest master, also reproduced on 1.2.3 and 1.2.2
How to reproduce:

  • Load a file in sfizz (either via zenity or with SFZ > browse without UI).
  • Do not wait till this message
[sfizz] File changed to: ...
[sfizz] Number of masters: 2
[sfizz] Number of groups: 6
[sfizz] Number of regions: 220
  • Try to interact with UI (e.g. press some button)

Message:

../../../src/cairo-xcb-screen.c:219: _get_screen_index: Assertion `!"reached"' failed.

Host: Reaper 7.15 on Debian 13.

Another way to reproduce (Reaper-specific):

  • When plugin loaded, select "Window float selected FX". Plugin will tear down the window and then crash.
  • (Alternative) Press "UI" button (toggle between native UI and Reaper's drawn UI) multiple times

I'll try to build sfizz-ui with debug info and provide detailed reports shortly

@myrrc
Copy link
Author

myrrc commented Apr 26, 2024

#0  __pthread_kill_implementation (threadid=<optimized out>, signo=signo@entry=6, no_tid=no_tid@entry=0) at ./nptl/pthread_kill.c:44
#1  0x00007ffff799c1cf in __pthread_kill_internal (signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:78
#2  0x00007ffff794e472 in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
#3  0x00007ffff79384b2 in __GI_abort () at ./stdlib/abort.c:79
#4  0x00007ffff79383d5 in __assert_fail_base
    (fmt=0x7ffff7aacdc8 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=assertion@entry=0x7ffff6c2e56f "!\"reached\"", file=file@entry=0x7ffff6c295d8 "../../../src/cairo-xcb-screen.c", line=line@entry=219, function=function@entry=0x7ffff6c3c990 "_get_screen_index") at ./assert/assert.c:92
#5  0x00007ffff79473a2 in __assert_fail
    (assertion=0x7ffff6c2e56f "!\"reached\"", file=0x7ffff6c295d8 "../../../src/cairo-xcb-screen.c", line=219, function=0x7ffff6c3c990 "_get_screen_index")
    at ./assert/assert.c:101
#6  0x00007ffff6bf418d in  () at /lib/x86_64-linux-gnu/libcairo.so.2
#7  0x00007ffff6bf68e3 in cairo_xcb_surface_create () at /lib/x86_64-linux-gnu/libcairo.so.2
#8  0x00007fffcdd8b9be in VSTGUI::X11::DrawHandler::DrawHandler(VSTGUI::X11::ChildWindow const&) (this=0x49bfca8, window=...)
    at /home/myrrc/src/sfizz-ui/plugins/editor/external/vstgui4/vstgui/lib/platform/linux/x11frame.cpp:171
#9  0x00007fffcdd8c424 in VSTGUI::X11::Frame::Impl::Impl(unsigned long, VSTGUI::CPoint, VSTGUI::IPlatformFrameCallback*)
    (this=0x49bfc80, parent=23072614, size=..., frame=0xe0c7140)
    at /home/myrrc/src/sfizz-ui/plugins/editor/external/vstgui4/vstgui/lib/platform/linux/x11frame.cpp:327
#10 0x00007fffcdd8aa26 in VSTGUI::X11::Frame::Frame(VSTGUI::IPlatformFrameCallback*, VSTGUI::CRect const&, unsigned int, VSTGUI::IPlatformFrameConfig*)
    (this=0xe10fb20, frame=0xe0c7140, size=..., parent=23072614, config=0x7fffffffc590, __in_chrg=<optimized out>, __vtt_parm=<optimized out>)
    at /home/myrrc/src/sfizz-ui/plugins/editor/external/vstgui4/vstgui/lib/platform/linux/x11frame.cpp:643
#11 0x00007fffcdd84d09 in VSTGUI::makeOwned<VSTGUI::X11::Frame, VSTGUI::IPlatformFrameCallback*&, VSTGUI::CRect const&, unsigned long&, VSTGUI::IPlatformFrameConfig*&>(VSTGUI::IPlatformFrameCallback*&, VSTGUI::CRect const&, unsigned long&, VSTGUI::IPlatformFrameConfig*&) ()
    at /home/myrrc/src/sfizz-ui/plugins/editor/external/vstgui4/vstgui/lib/platform/linux/../../vstguibase.h:469
#12 0x00007fffcdd83d22 in VSTGUI::LinuxFactory::createFrame(VSTGUI::IPlatformFrameCallback*, VSTGUI::CRect const&, void*, VSTGUI::PlatformType, VSTGUI::IPlatformFrameConfig*) const (this=0x7286be0, frame=0xe0c7140, size=..., parent=0x1600f66, parentType=VSTGUI::PlatformType::kDefaultNative, config=0x7fffffffc590)
    at /home/myrrc/src/sfizz-ui/plugins/editor/external/vstgui4/vstgui/lib/platform/linux/linuxfactory.cpp:96
#13 0x00007fffcdd3bca7 in VSTGUI::CFrame::open(void*, VSTGUI::PlatformType, VSTGUI::IPlatformFrameConfig*)
    (this=0xe0c7120, systemWin=0x1600f66, systemWindowType=VSTGUI::PlatformType::kDefaultNative, config=0x7fffffffc590)
    at /home/myrrc/src/sfizz-ui/plugins/editor/external/vstgui4/vstgui/lib/cframe.cpp:209
#14 0x00007fffcdc7a512 in instantiate(LV2UI_Descriptor const*, char const*, char const*, LV2UI_Write_Function, LV2UI_Controller, LV2UI_Widget*, LV2_Feature const* const*)
    (descriptor=0x7fffce106da0 <descriptor>, plugin_uri=0x7ffff4de3038 "http://sfztools.github.io/sfizz", bundle_path=0x4d55910 "/home/myrrc/.lv2/sfizz.lv2/", write_function=0xb76820, controller=0x578b960, widget=0x578cbb0, features=0x5795050) at /home/myrrc/src/sfizz-ui/plugins/lv2/sfizz_ui.cpp:292
#15 0x0000000000b76c59 in  ()
#16 0x0000000000b76f67 in  ()
#17 0x000000000081f85f in  ()
#18 0x0000000000824315 in  ()
#19 0x00000000007fad9e in  ()
#20 0x0000000000814367 in  ()
#21 0x00007ffff762b4d6 in  () at /opt/reaper/libSwell.so
#24 0x000000000040b04e in  ()
#25 0x00007ffff79396ca in __libc_start_call_main (main=main@entry=0x40a5b0, argc=argc@entry=1, argv=argv@entry=0x7fffffffe7f8)
    at ../sysdeps/nptl/libc_start_call_main.h:58
#26 0x00007ffff7939785 in __libc_start_main_impl
    (main=0x40a5b0, argc=1, argv=0x7fffffffe7f8, init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7fffffffe7e8)
    at ../csu/libc-start.c:360
#27 0x0000000000418b1a in _start ### ()

@myrrc
Copy link
Author

myrrc commented Apr 26, 2024

I assume the bug is not in sfizz but the vstgui4 library. I'll try to investigate (there have been reports of crashes that I've linked)

@myrrc
Copy link
Author

myrrc commented Apr 26, 2024

This issue also reproduces while building against latest vstgui from Steinberg

@paulfd
Copy link
Member

paulfd commented Jul 20, 2024

This happened before, and it was at some point one of the reason for me to pin VSTGUI. I think we "had" to unpin it some time ago for other reasons. If I find some time I'll investigate, thanks for reporting.

@paulfd paulfd self-assigned this Jul 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants