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 when opening LV2 UI while having Odin2 LV2 UI open in a DAW #292

Open
alex-tee opened this issue May 10, 2021 · 2 comments
Open

Comments

@alex-tee
Copy link

happens in both ardour and zrythm

valgrind output:

==1555156== Memcheck, a memory error detector
==1555156== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
==1555156== Using Valgrind-3.16.1 and LibVEX; rerun with -h for copyright info
==1555156== Command: build/src/zrythm --dummy --buf-size=16000
==1555156== Parent PID: 1514
==1555156== 
--1555156-- WARNING: unhandled amd64-linux syscall: 315
--1555156-- You may be able to write your own handler.
--1555156-- Read the file README_MISSING_SYSCALL_OR_IOCTL.
--1555156-- Nevertheless we consider this a bug.  Please report
--1555156-- it at http://valgrind.org/support/bug_reports.html.
--1555156-- WARNING: unhandled amd64-linux syscall: 439
--1555156-- You may be able to write your own handler.
--1555156-- Read the file README_MISSING_SYSCALL_OR_IOCTL.
--1555156-- Nevertheless we consider this a bug.  Please report
--1555156-- it at http://valgrind.org/support/bug_reports.html.
--1555156-- WARNING: unhandled amd64-linux syscall: 439
--1555156-- You may be able to write your own handler.
--1555156-- Read the file README_MISSING_SYSCALL_OR_IOCTL.
--1555156-- Nevertheless we consider this a bug.  Please report
--1555156-- it at http://valgrind.org/support/bug_reports.html.
--1555156-- WARNING: unhandled amd64-linux syscall: 439
--1555156-- You may be able to write your own handler.
--1555156-- Read the file README_MISSING_SYSCALL_OR_IOCTL.
--1555156-- Nevertheless we consider this a bug.  Please report
--1555156-- it at http://valgrind.org/support/bug_reports.html.
==1555156== Invalid read of size 8
==1555156==    at 0x7A7CC2AD: juce::Image::convertedToFormat(juce::Image::PixelFormat) const (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A7FED9B: juce::DropShadow::drawForImage(juce::Graphics&, juce::Image const&) const (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9BBC62: FullInterface::paintBackground(juce::Graphics&) (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9BC0FB: FullInterface::checkBackground() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9BC5C4: FullInterface::resized() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A854838: juce::Component::sendMovedResizedMessages(bool, bool) (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9E891D: HelmEditor::resized() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A854838: juce::Component::sendMovedResizedMessages(bool, bool) (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9E8867: HelmEditor::HelmEditor(HelmPlugin&) (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A963943: HelmPlugin::createEditor() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A6FEE9B: juce::AudioProcessor::createEditorIfNeeded() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A6D8C4B: JuceLv2UIWrapper::JuceLv2UIWrapper(juce::AudioProcessor*, void (*)(void*, unsigned int, unsigned int, unsigned int, void const*), void*, void**, _LV2_Feature const* const*, bool) (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==  Address 0x4f2fc7a0 is 8 bytes after a block of size 8 alloc'd
==1555156==    at 0x483EDEF: operator new(unsigned long) (vg_replace_malloc.c:342)
==1555156==    by 0x6CB13CF4: make_unique<juce::SoftwareImageType> (unique_ptr.h:962)
==1555156==    by 0x6CB13CF4: juce::SoftwarePixelData::createType() const (juce_Image.cpp:116)
==1555156==    by 0x7A7CC291: juce::Image::convertedToFormat(juce::Image::PixelFormat) const (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A7FED9B: juce::DropShadow::drawForImage(juce::Graphics&, juce::Image const&) const (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9BBC62: FullInterface::paintBackground(juce::Graphics&) (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9BC0FB: FullInterface::checkBackground() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9BC5C4: FullInterface::resized() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A854838: juce::Component::sendMovedResizedMessages(bool, bool) (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9E891D: HelmEditor::resized() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A854838: juce::Component::sendMovedResizedMessages(bool, bool) (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9E8867: HelmEditor::HelmEditor(HelmPlugin&) (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A963943: HelmPlugin::createEditor() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156== 
==1555156== Jump to the invalid address stated on the next line
==1555156==    at 0x100000008: ???
==1555156==    by 0x7A7FED9B: juce::DropShadow::drawForImage(juce::Graphics&, juce::Image const&) const (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9BBC62: FullInterface::paintBackground(juce::Graphics&) (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9BC0FB: FullInterface::checkBackground() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9BC5C4: FullInterface::resized() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A854838: juce::Component::sendMovedResizedMessages(bool, bool) (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9E891D: HelmEditor::resized() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A854838: juce::Component::sendMovedResizedMessages(bool, bool) (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9E8867: HelmEditor::HelmEditor(HelmPlugin&) (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A963943: HelmPlugin::createEditor() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A6FEE9B: juce::AudioProcessor::createEditorIfNeeded() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A6D8C4B: JuceLv2UIWrapper::JuceLv2UIWrapper(juce::AudioProcessor*, void (*)(void*, unsigned int, unsigned int, unsigned int, void const*), void*, void**, _LV2_Feature const* const*, bool) (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==  Address 0x100000008 is not stack'd, malloc'd or (recently) free'd
==1555156== 
==1555156== Invalid read of size 1
==1555156==    at 0x6686700: x86_64_fallback_frame_state (md-unwind-support.h:63)
==1555156==    by 0x6686700: uw_frame_state_for (unwind-dw2.c:1271)
==1555156==    by 0x668833A: _Unwind_Backtrace (unwind.inc:302)
==1555156==    by 0xAEF730: backtrace_full (in /home/alex/Documents/git/zrythm/build/src/zrythm)
==1555156==    by 0xAEF453: backtrace_print (in /home/alex/Documents/git/zrythm/build/src/zrythm)
==1555156==    by 0x9F289E: _backtrace_get (backtrace.c:333)
==1555156==    by 0x95708B: segv_handler (zrythm_app.c:147)
==1555156==    by 0x66CDF7F: ??? (in /usr/lib/libc-2.33.so)
==1555156==    by 0x100000007: ???
==1555156==    by 0x7A7FED9B: juce::DropShadow::drawForImage(juce::Graphics&, juce::Image const&) const (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9BBC62: FullInterface::paintBackground(juce::Graphics&) (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9BC0FB: FullInterface::checkBackground() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9BC5C4: FullInterface::resized() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==  Address 0x100000008 is not stack'd, malloc'd or (recently) free'd
==1555156== 
==1555156== 
==1555156== Process terminating with default action of signal 11 (SIGSEGV): dumping core
==1555156==  Access not within mapped region at address 0x100000008
==1555156==    at 0x6686700: x86_64_fallback_frame_state (md-unwind-support.h:63)
==1555156==    by 0x6686700: uw_frame_state_for (unwind-dw2.c:1271)
==1555156==    by 0x668833A: _Unwind_Backtrace (unwind.inc:302)
==1555156==    by 0xAEF730: backtrace_full (in /home/alex/Documents/git/zrythm/build/src/zrythm)
==1555156==    by 0xAEF453: backtrace_print (in /home/alex/Documents/git/zrythm/build/src/zrythm)
==1555156==    by 0x9F289E: _backtrace_get (backtrace.c:333)
==1555156==    by 0x95708B: segv_handler (zrythm_app.c:147)
==1555156==    by 0x66CDF7F: ??? (in /usr/lib/libc-2.33.so)
==1555156==    by 0x100000007: ???
==1555156==    by 0x7A7FED9B: juce::DropShadow::drawForImage(juce::Graphics&, juce::Image const&) const (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9BBC62: FullInterface::paintBackground(juce::Graphics&) (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9BC0FB: FullInterface::checkBackground() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==    by 0x7A9BC5C4: FullInterface::resized() (in /usr/lib/lv2/helm-synth.lv2/helm-synth.so)
==1555156==  If you believe this happened as a result of a stack
==1555156==  overflow in your program's main thread (unlikely but
==1555156==  possible), you can try to increase the size of the
==1555156==  main thread stack using the --main-stacksize= flag.
==1555156==  The main thread stack size used in this run was 8388608.
==1555156== 
==1555156== HEAP SUMMARY:
==1555156==     in use at exit: 1,215,418,747 bytes in 2,203,548 blocks
==1555156==   total heap usage: 12,304,552 allocs, 10,101,004 frees, 4,971,582,871 bytes allocated
==1555156== 
==1555156== LEAK SUMMARY:
==1555156==    definitely lost: 4,215,833 bytes in 1,037 blocks
==1555156==    indirectly lost: 535,858 bytes in 16,290 blocks
==1555156==      possibly lost: 2,662,412 bytes in 11,985 blocks
==1555156==    still reachable: 1,133,248,057 bytes in 1,347,480 blocks
==1555156==                       of which reachable via heuristic:
==1555156==                         multipleinheritance: 126,776 bytes in 1,926 blocks
==1555156==         suppressed: 70,066,291 bytes in 795,405 blocks
==1555156== Rerun with --leak-check=full to see details of leaked memory
==1555156== 
==1555156== For lists of detected and suppressed errors, rerun with: -s
==1555156== ERROR SUMMARY: 3 errors from 3 contexts (suppressed: 10 from 10)
@x42
Copy link

x42 commented May 23, 2021

Looks like JUCE symbol conflicts.
Both plugins should be built with hidden and local symbols, and not expose JUCE into the global namespace.

@jcelerier
Copy link

also had this crash with the vst version

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

3 participants