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

crash when loading preview of cf player module #92

Closed
roberChen opened this issue Dec 12, 2021 · 11 comments · Fixed by CardinalModules/cf#1
Closed

crash when loading preview of cf player module #92

roberChen opened this issue Dec 12, 2021 · 11 comments · Fixed by CardinalModules/cf#1

Comments

@roberChen
Copy link

roberChen commented Dec 12, 2021

I've encountered with this bug too many times. When I perform a text search on modules, it will likely to crash (I want to search filter and when I typed f it will crash ).
console output:

[29.248 info Window.cpp:73 loadFile] Loaded font /usr/lib/lv2/CardinalSynth.lv2/resources/cf/Segment7Standard.ttf
[29.313 info Window.cpp:73 loadFile] Loaded font /usr/lib/lv2/CardinalSynth.lv2/resources/cf/LEDCalculator.ttf
/usr/include/c++/11.1.0/bits/basic_string.h:1045: std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::reference std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::operator[](std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type) [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::reference = char&; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type = long unsigned int]: Assertion '__pos <= size()' failed.
[1]    137552 abort (core dumped)  ardour6

cardinal plugin load info starts with:

[0.000 info CardinalPlugin.cpp:137 Initializer] Cardinal LV2 v2.0
[0.000 info CardinalPlugin.cpp:138 Initializer] Linux 5.15.7-1-MANJARO #1 SMP PREEMPT Wed Dec 8 10:09:19 UTC 2021 x86_64
[0.000 info CardinalPlugin.cpp:139 Initializer] Binary filename: /usr/lib/lv2/CardinalSynth.lv2/CardinalSynth.so
[0.000 info CardinalPlugin.cpp:140 Initializer] Bundle path: /usr/lib/lv2/CardinalSynth.lv2/
[0.000 info CardinalPlugin.cpp:141 Initializer] System directory: /usr/lib/lv2/CardinalSynth.lv2//resources
[0.000 info CardinalPlugin.cpp:142 Initializer] User directory: /usr/lib/lv2/CardinalSynth.lv2//resources
[0.000 info CardinalPlugin.cpp:143 Initializer] Template patch: /usr/lib/lv2/CardinalSynth.lv2/resources/template.vcv

using Ardour6.9.0 (built using 6.9 and GCC version 11.1.0), and cardinal-git Version : r451.353594a-1

note that this bug has been existing at least several days, with many rebuilt to sync with newest version. Also, I was using pipewire-alsa but I think this is noting related to it.

@falkTX
Copy link
Contributor

falkTX commented Dec 12, 2021

I fixed some conflicts that were happening today, so I think this is fixed now.
a full rebuild is needed.

@falkTX
Copy link
Contributor

falkTX commented Dec 12, 2021

worth trying with the standalone too, since you are building it yourself.
should be easier to get more info about it that way

@roberChen roberChen changed the title crash when search modules crash when loading preview of cf player module Dec 24, 2021
@roberChen
Copy link
Author

roberChen commented Dec 28, 2021

coredump backtrace:

(gdb) bt -full 
#0  0x00007f03fa057d22 in raise () at /usr/lib/libc.so.6
#1  0x00007f03fa041862 in abort () at /usr/lib/libc.so.6
#2  0x000055f0b880c00a in std::__replacement_assert(char const*, int, char const*, char const*)
    (__file=__file@entry=0x55f0b9a7a408 "/usr/include/c++/11.1.0/bits/basic_string.h", __line=__line@entry=1045, __function=__function@entry=0x55f0b9a7a250 "std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::reference std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::operator[](std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type) [with _Ch"..., __condition=__condition@entry=0x55f0b9a77c2f "__pos <= size()") at /usr/include/c++/11.1.0/x86_64-pc-linux-gnu/bits/c++config.h:504
#3  0x000055f0b8fd0800 in std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::operator[](unsigned long) (this=0x7ffd2525b5c0, __pos=12)
    at /usr/include/c++/11.1.0/bits/basic_string.h:1041
        i = <optimized out>
        font = std::shared_ptr<rack::window::Font> (use count 2, weak count 0) = {get() = 0x55f0bf970690}
        fD = "load sample"
        to_display = "load sample"
#4  std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::operator[](unsigned long) (__pos=12, this=0x7ffd2525b5c0) at /usr/include/c++/11.1.0/bits/basic_string.h:1041
        i = <optimized out>
        font = std::shared_ptr<rack::window::Font> (use count 2, weak count 0) = {get() = 0x55f0bf970690}
        fD = "load sample"
        to_display = "load sample"
#5  PLAYDisplay::drawLayer(rack::widget::Widget::DrawArgs const&, int) (this=0x55f0bf204e60, args=..., layer=1) at cf/src/PLAY.cpp:254
        i = <optimized out>
        font = std::shared_ptr<rack::window::Font> (use count 2, weak count 0) = {get() = 0x55f0bf970690}
        fD = "load sample"
        to_display = "load sample"
#6  0x000055f0b96faa99 in rack::widget::Widget::drawChild(rack::widget::Widget*, rack::widget::Widget::DrawArgs const&, int)
    (this=this@entry=0x55f0bf204350, child=child@entry=0x55f0bf204e60, args=..., layer=layer@entry=1) at Rack/src/widget/Widget.cpp:319
        childArgs = {vg = 0x55f0bda84160, clipBox = {pos = {x = 0, y = 0}, size = {x = 12, y = 127}}, fb = 0x55f0bf956460}
#7  0x000055f0b96fac85 in rack::widget::Widget::drawLayer(rack::widget::Widget::DrawArgs const&, int) (this=0x55f0bf204350, args=..., layer=1) at Rack/src/widget/Widget.cpp:295
        child = 0x55f0bf204e60
        __for_range = 
          std::__cxx11::list = {[0] = 0x55f0bf204bf0, [1] = 0x55f0bf204e60, [2] = 0x55f0bf204ee0, [3] = 0x55f0bf2057a0, [4] = 0x55f0bf202270, [5] = 0x55f0bf205d00, [6] = 0x55f0bf205f80, [7] = 0x55f0bf206240, [8] = 0x55f0bf207270}
#8  0x000055f0b96faa99 in rack::widget::Widget::drawChild(rack::widget::Widget*, rack::widget::Widget::DrawArgs const&, int)
    (this=this@entry=0x55f0bf2042e0, child=child@entry=0x55f0bf204350, args=..., layer=layer@entry=1) at Rack/src/widget/Widget.cpp:319
        childArgs = {vg = 0x55f0bda84160, clipBox = {pos = {x = 0, y = 0}, size = {x = 30, y = 380}}, fb = 0x55f0bf956460}
#9  0x000055f0b96fac85 in rack::widget::Widget::drawLayer(rack::widget::Widget::DrawArgs const&, int) (this=0x55f0bf2042e0, args=..., layer=1) at Rack/src/widget/Widget.cpp:295
        child = 0x55f0bf204350
        __for_range = std::__cxx11::list = {[0] = 0x55f0bf204350}
#10 0x000055f0b96faa5c in rack::widget::Widget::drawChild(rack::widget::Widget*, rack::widget::Widget::DrawArgs const&, int)
    (this=this@entry=0x55f0bf2041f0, child=child@entry=0x55f0bf2042e0, args=..., layer=layer@entry=0) at Rack/src/widget/Widget.cpp:311
        childArgs = {vg = 0x55f0bda84160, clipBox = {pos = {x = 0, y = 0}, size = {x = 30, y = 380}}, fb = 0x55f0bf956460}
#11 0x000055f0b96fab8c in rack::widget::Widget::draw(rack::widget::Widget::DrawArgs const&) (this=this@entry=0x55f0bf2041f0, args=...) at Rack/src/widget/Widget.cpp:280
        child = 0x55f0bf2042e0
        __for_range = std::__cxx11::list = {[0] = 0x55f0bf2042e0}
#12 0x000055f0b96f801a in rack::widget::FramebufferWidget::drawFramebuffer() (this=0x55f0bf2041f0) at Rack/src/widget/FramebufferWidget.cpp:287
        vg = 0x55f0bda84160
        pixelRatio = <optimized out>
        args = {vg = 0x55f0bda84160, clipBox = {pos = {x = 0, y = 0}, size = {x = inf, y = inf}}, fb = 0x55f0bf956460}
#13 0x000055f0b96f8b82 in rack::widget::FramebufferWidget::render(rack::math::Vec, rack::math::Vec, rack::math::Rect) (this=0x55f0bf2041f0, scale=..., offsetF=..., clipBox=...)
    at Rack/src/widget/FramebufferWidget.cpp:241
        fb = 0x55f0bf954620
        oversampledFbSize = {x = 30, y = 380}
        oversampledFb = 0x55f0bf956460
        paint = 
--Type <RET> for more, q to quit, c to continue without paging--
          {xform = {1.4374255e-16, 4.59135442e-41, 0, 0, 0.5, 0}, extent = {0, 0}, radius = 5.60519386e-45, feather = 0, innerColor = {{rgba = {-1.84455938e+35, 4.55632196e-41, 0, 0}, {r = -1.84455938e+35, g = 4.55632196e-41, b = 0, a = 0}}}, outerColor = {{rgba = {-0.626006126, 3.08285662e-41, 1.43746785e-16, 4.59135442e-41}, {r = -0.626006126, g = 3.08285662e-41, b = 1.43746785e-16, a = 4.59135442e-41}}}, image = -1184361338}
        vg = <optimized out>
        fbVg = 0x55f0bda84160
        localBox = {pos = {x = <optimized out>, y = <optimized out>}, size = {x = <optimized out>, y = <optimized out>}}
        pixelRatio = <optimized out>
        newFbSize = {x = <optimized out>, y = <optimized out>}
        __FUNCTION__ = "render"
#14 0x000055f0b96f9324 in rack::widget::FramebufferWidget::draw(rack::widget::Widget::DrawArgs const&) (this=0x55f0bf2041f0, args=...) at Rack/src/widget/FramebufferWidget.cpp:125
        xform = {0.5, 0, 0, 0.5, 1832, 83}
        __FUNCTION__ = "draw"
        scale = {x = <optimized out>, y = <optimized out>}
        offsetI = {x = 1832, y = 83}
        offsetF = {x = <optimized out>, y = <optimized out>}
        offsetFDelta = {x = <optimized out>, y = <optimized out>}
        scaleRatio = {x = <optimized out>, y = <optimized out>}
        paint = 
          {xform = {1, 0, -0, 1, 1754, 83}, extent = {68, 190}, radius = 0, feather = 0, innerColor = {{rgba = {-6.37453704e-05, 3.08285662e-41, 0.5, 0}, {r = -6.37453704e-05, g = 3.08285662e-41, b = 0.5, a = 0}}}, outerColor = {{rgba = {0, 0.5, 1832, 83}, {r = 0, g = 0.5, b = 1832, a = 83}}}, image = 861245952}
#15 0x000055f0b96faa5c in rack::widget::Widget::drawChild(rack::widget::Widget*, rack::widget::Widget::DrawArgs const&, int)
    (this=this@entry=0x55f0bf203e90, child=child@entry=0x55f0bf2041f0, args=..., layer=layer@entry=0) at Rack/src/widget/Widget.cpp:311
        childArgs = {vg = 0x55f0bd9f9c20, clipBox = {pos = {x = 0, y = 0}, size = {x = 30, y = 380}}, fb = 0x0}
#16 0x000055f0b96fab8c in rack::widget::Widget::draw(rack::widget::Widget::DrawArgs const&) (this=this@entry=0x55f0bf203e90, args=...) at Rack/src/widget/Widget.cpp:280
        child = 0x55f0bf2041f0
        __for_range = std::__cxx11::list = {[0] = 0x55f0bf2041f0}
#17 0x000055f0b96faf3b in rack::widget::ZoomWidget::draw(rack::widget::Widget::DrawArgs const&) (this=0x55f0bf203e90, args=<optimized out>) at Rack/src/widget/ZoomWidget.cpp:54
        zoomCtx = {vg = 0x55f0bd9f9c20, clipBox = {pos = {x = 0, y = 0}, size = {x = 30, y = 380}}, fb = 0x0}
#18 0x000055f0b96faa5c in rack::widget::Widget::drawChild(rack::widget::Widget*, rack::widget::Widget::DrawArgs const&, int)
    (this=this@entry=0x55f0bf203be0, child=child@entry=0x55f0bf203e90, args=..., layer=layer@entry=0) at Rack/src/widget/Widget.cpp:311
        childArgs = {vg = 0x55f0bd9f9c20, clipBox = {pos = {x = 0, y = 0}, size = {x = 15, y = 190}}, fb = 0x0}
#19 0x000055f0b96fab8c in rack::widget::Widget::draw(rack::widget::Widget::DrawArgs const&) (this=0x55f0bf203be0, args=...) at Rack/src/widget/Widget.cpp:280
        child = 0x55f0bf203e90
        __for_range = std::__cxx11::list = {[0] = 0x55f0bf203e90}
#20 0x000055f0b96faa5c in rack::widget::Widget::drawChild(rack::widget::Widget*, rack::widget::Widget::DrawArgs const&, int)
    (this=this@entry=0x55f0bd109a00, child=child@entry=0x55f0bf203be0, args=..., layer=layer@entry=0) at Rack/src/widget/Widget.cpp:311
        childArgs = {vg = 0x55f0bd9f9c20, clipBox = {pos = {x = 0, y = 0}, size = {x = 15, y = 190}}, fb = 0x0}
#21 0x000055f0b96fab8c in rack::widget::Widget::draw(rack::widget::Widget::DrawArgs const&) (this=this@entry=0x55f0bd109a00, args=...) at Rack/src/widget/Widget.cpp:280
        child = 0x55f0bf203be0
        __for_range = std::__cxx11::list = {[0] = 0x55f0bf203be0}
#22 0x000055f0b9691ff7 in rack::app::browser::ModelBox::draw(rack::widget::Widget::DrawArgs const&) (this=0x55f0bd109a00, args=...) at Rack/src/app/Browser.cpp:217
        b = <optimized out>
        mi = <optimized out>
#23 0x000055f0b96faa5c in rack::widget::Widget::drawChild(rack::widget::Widget*, rack::widget::Widget::DrawArgs const&, int)
    (this=this@entry=0x55f0bd0f6c80, child=child@entry=0x55f0bd109a00, args=..., layer=layer@entry=0) at Rack/src/widget/Widget.cpp:311
        childArgs = {vg = 0x55f0bd9f9c20, clipBox = {pos = {x = 0, y = 0}, size = {x = 15, y = 190}}, fb = 0x0}
#24 0x000055f0b96fab8c in rack::widget::Widget::draw(rack::widget::Widget::DrawArgs const&) (this=0x55f0bd0f6c80, args=...) at Rack/src/widget/Widget.cpp:280
        child = 0x55f0bd109a00
        __for_range = 
          std::__cxx11::list = {[0] = 0x55f0bd0fc440, [1] = 0x55f0bd0fc530, [2] = 0x55f0bd0fc620, [3] = 0x55f0bd0fc710, [4] = 0x55f0bd0fc800, [5] = 0x55f0bd0fc8f0, [6] = 0x55f0bd0fc9e0, [7] = 0x55f0bd0fcad0, [8] = 0x55f0bd0fcbc0, [9] = 0x55f0bd103100, [10] = 0x55f0bd136f60, [11] = 0x55f0bd103880, [12] = 0x55f0bd126700, [13] = 0x55f0bd0fbae0, [14] = 0x55f0bd100b80, [15] = 0x55f0bd12af30, [16] = 0x55f0bd12b020, [17] = 0x55f0bd12df00, [18] = 0x55f0bd109370, [19] = 0x55f0bd109460, [20] = 0x55f0bd109550, [21] = 0x55f0bd109640, [22] = 0x55f0bd109730, [23] = 0x55f0bd109820, [24] = 0x55f0bd109910, [25] = 0x55f0bd109a00, [26] = 0x55f0bd1--Type <RET> for more, q to quit, c to continue without paging--
09af0, [27] = 0x55f0bd122b20, [28] = 0x55f0bd122bf0, [29] = 0x55f0bd122ce0, [30] = 0x55f0bd122dd0, [31] = 0x55f0bd122ec0, [32] = 0x55f0bd122fb0, [33] = 0x55f0bd1230a0, [34] = 0x55f0bd123190, [35] = 0x55f0bd123280, [36] = 0x55f0bd123370, [37] = 0x55f0bd123460, [38] = 0x55f0bd123550, [39] = 0x55f0bd123640, [40] = 0x55f0bd123730, [41] = 0x55f0bd123820, [42] = 0x55f0bd123910, [43] = 0x55f0bd123a00, [44] = 0x55f0bd134170, [45] = 0x55f0bd101f30, [46] = 0x55f0bd102980, [47] = 0x55f0bd1032e0, [48] = 0x55f0bd1034c0, [49] = 0x55f0bd1035b0, [50] = 0x55f0bd127150, [51] = 0x55f0bd127240, [52] = 0x55f0bd0f8570, [53] = 0x55f0bd0fe330, [54] = 0x55f0bd0fe420, [55] = 0x55f0bd104a50, [56] = 0x55f0bd126070, [57] = 0x55f0bd126160, [58] = 0x55f0bd126250, [59] = 0x55f0bd126340, [60] = 0x55f0bd126430, [61] = 0x55f0bd126520, [62] = 0x55f0bd126610, [63] = 0x55f0bd1267f0, [64] = 0x55f0bd1268e0, [65] = 0x55f0bd1269d0, [66] = 0x55f0bd126ac0, [67] = 0x55f0bd126bb0, [68] = 0x55f0bd136420, [69] = 0x55f0bd124180, [70] = 0x55f0bd0f9650, [71] = 0x55f0bd101b70, [72] = 0x55f0bd1036a0, [73] = 0x55f0bd105a40, [74] = 0x55f0bd12c4c0, [75] = 0x55f0bd12c5b0, [76] = 0x55f0bd126e80, [77] = 0x55f0bd136c90, [78] = 0x55f0bd1033d0, [79] = 0x55f0bd108830, [80] = 0x55f0bd108ce0, [81] = 0x55f0bd12ae40, [82] = 0x55f0bd12c6a0, [83] = 0x55f0bd134bc0, [84] = 0x55f0bd1017b0, [85] = 0x55f0bd0ff230, [86] = 0x55f0bd0ff320, [87] = 0x55f0bd0ff410, [88] = 0x55f0bd0ff500, [89] = 0x55f0bd0ff5f0, [90] = 0x55f0bd0ff6e0, [91] = 0x55f0bd0ff7d0, [92] = 0x55f0bd0ff8c0, [93] = 0x55f0bd0ff9b0, [94] = 0x55f0bd0ffaa0, [95] = 0x55f0bd0ffb90, [96] = 0x55f0bd0ffc80, [97] = 0x55f0bd0ffd70, [98] = 0x55f0bd0ffe60, [99] = 0x55f0bd0fff50, [100] = 0x55f0bd100040, [101] = 0x55f0bd100130, [102] = 0x55f0bd103790, [103] = 0x55f0bd107c00, [104] = 0x55f0bd135ca0, [105] = 0x55f0bd126ca0, [106] = 0x55f0bd126d90, [107] = 0x55f0bd126f70, [108] = 0x55f0bd127060, [109] = 0x55f0bd127330, [110] = 0x55f0bd127420, [111] = 0x55f0bd127510, [112] = 0x55f0bd127600, [113] = 0x55f0bd1276f0, [114] = 0x55f0bd1277e0, [115] = 0x55f0bd1278d0, [116] = 0x55f0bd1279c0, [117] = 0x55f0bd127ab0, [118] = 0x55f0bd127ba0, [119] = 0x55f0bd127c90, [120] = 0x55f0bd127d80, [121] = 0x55f0bd127e70, [122] = 0x55f0bd127f60, [123] = 0x55f0bd128050, [124] = 0x55f0bd128140, [125] = 0x55f0bd128230, [126] = 0x55f0bd128320, [127] = 0x55f0bd128410, [128] = 0x55f0bd128500, [129] = 0x55f0bd1285f0, [130] = 0x55f0bd132370, [131] = 0x55f0bd0fadc0, [132] = 0x55f0bd12fd00, [133] = 0x55f0bd0fe060, [134] = 0x55f0bd130570, [135] = 0x55f0bd123dc0, [136] = 0x55f0bd104000, [137] = 0x55f0bd108290, [138] = 0x55f0bd0f8a20, [139] = 0x55f0bd1041e0, [140] = 0x55f0bd108380, [141] = 0x55f0bd12f1c0, [142] = 0x55f0bd12f2b0, [143] = 0x55f0bd12f3a0, [144] = 0x55f0bd12f490, [145] = 0x55f0bd12f580, [146] = 0x55f0bd12f670, [147] = 0x55f0bd12f760, [148] = 0x55f0bd12f850, [149] = 0x55f0bd12f940, [150] = 0x55f0bd12fa30, [151] = 0x55f0bd12fb20, [152] = 0x55f0bd12fc10, [153] = 0x55f0bd12a210, [154] = 0x55f0bd136510, [155] = 0x55f0bd12e4a0, [156] = 0x55f0bd123be0, [157] = 0x55f0bd0fccb0, [158] = 0x55f0bd0fcda0, [159] = 0x55f0bd0f7df0, [160] = 0x55f0bd130c00, [161] = 0x55f0bd130de0, [162] = 0x55f0bd133ea0, [163] = 0x55f0bd0f81b0, [164] = 0x55f0bd0f8ed0, [165] = 0x55f0bd0f91a0, [166] = 0x55f0bd0fa0a0, [167] = 0x55f0bd0fa190, [168] = 0x55f0bd0fa280, [169] = 0x55f0bd0fa460, [170] = 0x55f0bd0fa550, [171] = 0x55f0bd0fa640, [172] = 0x55f0bd0fa730, [173] = 0x55f0bd100310, [174] = 0x55f0bd1015d0, [175] = 0x55f0bd102a70, [176] = 0x55f0bd1052c0, [177] = 0x55f0bd1054a0, [178] = 0x55f0bd105d10, [179] = 0x55f0bd1062b0, [180] = 0x55f0bd106490, [181] = 0x55f0bd106580, [182] = 0x55f0bd107390, [183] = 0x55f0bd107570, [184] = 0x55f0bd107a20, [185] = 0x55f0bd108740, [186] = 0x55f0bd128aa0, [187] = 0x55f0bd1298b0, [188] = 0x55f0bd12a300, [189] = 0x55f0bd12c010, [190] = 0x55f0bd12c1f0, [191] = 0x55f0bd12c880, [192] = 0x55f0bd12cd30, [193] = 0x55f0bd130930, [194] = 0x55f0bd130ed0, [195] = 0x55f0bd130fc0, [196] = 0x55f0bd1310b0, [197] = 0x55f0bd1311a0, [198] = 0x55f0bd131290, [199] = 0x55f0bd131380...}
#25 0x000055f0b96faa5c in rack::widget::Widget::drawChild(rack::widget::Widget*, rack::widget::Widget::DrawArgs const&, int)
    (this=this@entry=0x55f0bd0f6c10, child=child@entry=0x55f0bd0f6c80, args=..., layer=layer@entry=0) at Rack/src/widget/Widget.cpp:311
        childArgs = {vg = 0x55f0bd9f9c20, clipBox = {pos = {x = 0, y = 0}, size = {x = 1830, y = 864}}, fb = 0x0}
#26 0x000055f0b96fab8c in rack::widget::Widget::draw(rack::widget::Widget::DrawArgs const&) (this=0x55f0bd0f6c10, args=...) at Rack/src/widget/Widget.cpp:280
        child = 0x55f0bd0f6c80
        __for_range = std::__cxx11::list = {[0] = 0x55f0bd0f6c80}
#27 0x000055f0b96faa5c in rack::widget::Widget::drawChild(rack::widget::Widget*, rack::widget::Widget::DrawArgs const&, int)
    (this=this@entry=0x55f0bd0f6a80, child=child@entry=0x55f0bd0f6c10, args=..., layer=layer@entry=0) at Rack/src/widget/Widget.cpp:311
        childArgs = {vg = 0x55f0bd9f9c20, clipBox = {pos = {x = 0, y = 0}, size = {x = 1840, y = 864}}, fb = 0x0}
#28 0x000055f0b96fab8c in rack::widget::Widget::draw(rack::widget::Widget::DrawArgs const&) (this=0x55f0bd0f6a80, args=...) at Rack/src/widget/Widget.cpp:280
        child = 0x55f0bd0f6c10
        __for_range = std::__cxx11::list = {[0] = 0x55f0bd0f6c10}
#29 0x000055f0b96faa5c in rack::widget::Widget::drawChild(rack::widget::Widget*, rack::widget::Widget::DrawArgs const&, int)
    (this=this@entry=0x55f0bd0f69d0, child=child@entry=0x55f0bd0f6a80, args=..., layer=layer@entry=0) at Rack/src/widget/Widget.cpp:311
        childArgs = {vg = 0x55f0bd9f9c20, clipBox = {pos = {x = 0, y = 0}, size = {x = 1840, y = 864}}, fb = 0x0}
#30 0x000055f0b96fab8c in rack::widget::Widget::draw(rack::widget::Widget::DrawArgs const&) (this=this@entry=0x55f0bd0f69d0, args=...) at Rack/src/widget/Widget.cpp:280
        child = 0x55f0bd0f6a80
        __for_range = std::__cxx11::list = {[0] = 0x55f0bd0f6a80, [1] = 0x55f0bd0f6af0, [2] = 0x55f0bd0f6b70}
#31 0x000055f0b96f1e79 in rack::ui::ScrollWidget::draw(rack::widget::Widget::DrawArgs const&) (this=0x55f0bd0f69d0, args=...) at Rack/src/ui/ScrollWidget.cpp:68
#32 0x000055f0b96faa5c in rack::widget::Widget::drawChild(rack::widget::Widget*, rack::widget::Widget::DrawArgs const&, int)
    (this=this@entry=0x55f0bd0f61d0, child=child@entry=0x55f0bd0f69d0, args=..., layer=layer@entry=0) at Rack/src/widget/Widget.cpp:311
        childArgs = {vg = 0x55f0bd9f9c20, clipBox = {pos = {x = 0, y = 0}, size = {x = 1840, y = 864}}, fb = 0x0}
#33 0x000055f0b96fab8c in rack::widget::Widget::draw(rack::widget::Widget::DrawArgs const&) (this=0x55f0bd0f61d0, args=...) at Rack/src/widget/Widget.cpp:280
        child = 0x55f0bd0f69d0
        __for_range = std::__cxx11::list = {[0] = 0x55f0bd0f4dc0, [1] = 0x55f0bd0f69d0}
#34 0x000055f0b96faa5c in rack::widget::Widget::drawChild(rack::widget::Widget*, rack::widget::Widget::DrawArgs const&, int)
    (this=this@entry=0x55f0bd0f6170, child=child@entry=0x55f0bd0f61d0, args=..., layer=layer@entry=0) at Rack/src/widget/Widget.cpp:311
        childArgs = {vg = 0x55f0bd9f9c20, clipBox = {pos = {x = 0, y = 0}, size = {x = 1840, y = 905}}, fb = 0x0}
#35 0x000055f0b96fab8c in rack::widget::Widget::draw(rack::widget::Widget::DrawArgs const&) (this=0x55f0bd0f6170, args=...) at Rack/src/widget/Widget.cpp:280
        child = 0x55f0bd0f61d0
        __for_range = std::__cxx11::list = {[0] = 0x55f0bd0f61d0}
#36 0x000055f0b96faa5c in rack::widget::Widget::drawChild(rack::widget::Widget*, rack::widget::Widget::DrawArgs const&, int)
--Type <RET> for more, q to quit, c to continue without paging--
    (this=this@entry=0x55f0bd0f48d0, child=child@entry=0x55f0bd0f6170, args=..., layer=layer@entry=0) at Rack/src/widget/Widget.cpp:311
        childArgs = {vg = 0x55f0bd9f9c20, clipBox = {pos = {x = 0, y = 0}, size = {x = 1920, y = 985}}, fb = 0x0}
#37 0x000055f0b96fab8c in rack::widget::Widget::draw(rack::widget::Widget::DrawArgs const&) (this=0x55f0bd0f48d0, args=...) at Rack/src/widget/Widget.cpp:280
        child = 0x55f0bd0f6170
        __for_range = std::__cxx11::list = {[0] = 0x55f0bd9ffe90, [1] = 0x55f0bd0f4950, [2] = 0x55f0bd0f6170, [3] = 0x55f0bd141f70}
#38 0x000055f0b87fdd4d in rack::window::Window::step() (this=0x55f0bd141fc0) at Window.cpp:397
        args = {vg = 0x55f0bd9f9c20, clipBox = {pos = {x = 0, y = 0}, size = {x = 1920, y = 985}}, fb = 0x0}
        frameTime = <optimized out>
        lastFrameTime = <optimized out>
        windowTitle = "Cardinal Audio Plugin 2.0"
        newPixelRatio = <optimized out>
        winWidth = 1920
        winHeight = 985
        fbWidth = 1920
        fbHeight = 985
#39 0x000055f0b87fc357 in DISTRHO::CardinalUI::onNanoDisplay() (this=0x55f0bd9bed90) at CardinalUI.cpp:326
        sc = {context = 0x55f0bcc52960}
#40 DGL::NanoBaseWidget<DGL::TopLevelWidget>::onDisplay() (this=0x55f0bd9bed90) at ../../dpf/distrho/../dgl/NanoVG.hpp:961
#41 0x000055f0b882fea5 in DGL::TopLevelWidget::PrivateData::display() (this=0x55f0bda02110) at src/OpenGL.cpp:662
        size = {fWidth = 1920, fHeight = 985}
        width = 1920
        height = 985
        autoScaleFactor = <optimized out>
#42 0x000055f0b882b2e3 in DGL::Window::PrivateData::onPuglExpose() (this=0x55f0bd9beec0) at src/WindowPrivateData.cpp:597
        widget = 0x55f0bd9bed90
        it = 0x55f0bd9bed90
#43 0x000055f0b882bef3 in DGL::Window::PrivateData::puglEventCallback(DGL::PuglViewImpl*, DGL::PuglEvent const*) (view=0x55f0bd9bef80, event=0x7ffd2525c4d0) at src/WindowPrivateData.cpp:795
        pData = 0x55f0bd9beec0
#44 0x000055f0b887144a in DGL::flushExposures (world=0x55f0bd9265b0) at src/pugl-upstream/src/x11.c:1113
        view = 0x55f0bd9bef80
        configure = 
            {any = {type = DGL::PUGL_NOTHING, flags = 1}, type = DGL::PUGL_NOTHING, button = {type = DGL::PUGL_NOTHING, flags = 1, time = 0, x = 58, y = 1920, xRoot = 985, yRoot = 0, state = 0, button = 0}, configure = {type = DGL::PUGL_NOTHING, flags = 1, x = 0, y = 58, width = 1920, height = 985}, expose = {type = DGL::PUGL_NOTHING, flags = 1, x = 0, y = 58, width = 1920, height = 985}, key = {type = DGL::PUGL_NOTHING, flags = 1, time = 0, x = 58, y = 1920, xRoot = 985, yRoot = 0, state = 0, keycode = 0, key = 0}, text = {type = DGL::PUGL_NOTHING, flags = 1, time = 0, x = 58, y = 1920, xRoot = 985, yRoot = 0, state = 0, keycode = 0, character = 0, string = "\000\000\000\000\000\000\000"}, crossing = {type = DGL::PUGL_NOTHING, flags = 1, time = 0, x = 58, y = 1920, xRoot = 985, yRoot = 0, state = 0, mode = DGL::PUGL_CROSSING_NORMAL}, motion = {type = DGL::PUGL_NOTHING, flags = 1, time = 0, x = 58, y = 1920, xRoot = 985, yRoot = 0, state = 0}, scroll = {type = DGL::PUGL_NOTHING, flags = 1, time = 0, x = 58, y = 1920, xRoot = 985, yRoot = 0, state = 0, direction = DGL::PUGL_SCROLL_UP, dx = 0, dy = 0}, focus = {type = DGL::PUGL_NOTHING, flags = 1, mode = DGL::PUGL_CROSSING_NORMAL}, client = {type = DGL::PUGL_NOTHING, flags = 1, data1 = 0, data2 = 4633359591634108416}, timer = {type = DGL::PUGL_NOTHING, flags = 1, id = 0}}
        expose = 
            {any = {type = DGL::PUGL_EXPOSE, flags = 1}, type = DGL::PUGL_EXPOSE, button = {type = DGL::PUGL_EXPOSE, flags = 1, time = 0, x = 0, y = 1920, xRoot = 985, yRoot = 0, state = 0, button = 0}, configure = {type = DGL::PUGL_EXPOSE, flags = 1, x = 0, y = 0, width = 1920, height = 985}, expose = {type = DGL::PUGL_EXPOSE, flags = 1, x = 0, y = 0, width = 1920, height = 985}, key = {type = DGL::PUGL_EXPOSE, flags = 1, time = 0, x = 0, y = 1920, xRoot = 985, yRoot = 0, state = 0, keycode = 0, key = 0}, text = {type = DGL::PUGL_EXPOSE, flags = 1, time = 0, x = 0, y = 1920, xRoot = 985, yRoot = 0, state = 0, keycode = 0, character = 0, string = "\000\000\000\000\000\000\000"}, crossing = {type = DGL::PUGL_EXPOSE, flags = 1, time = 0, x = 0, y = 1920, xRoot = 985, yRoot = 0, state = 0, mode = DGL::PUGL_CROSSING_NORMAL}, motion = {type = DGL::PUGL_EXPOSE, flags = 1, time = 0, x = 0, y = 1920, xRoot = 985, yRoot = 0, state = 0}, scroll = {type = DGL::PUGL_EXPOSE, flags = 1, time = 0, x = 0, y = 1920, xRoot = 985, yRoot = 0, state = 0, direction = DGL::PUGL_SCROLL_UP, dx = 0, dy = 0}, focus = {type = DGL::PUGL_EXPOSE, flags = 1, mode = DGL::PUGL_CROSSING_NORMAL}, client = {type = DGL::PUGL_EXPOSE, flags = 1, data1 = 0, data2 = 0}, timer = {type = DGL::PUGL_EXPOSE, flags = 1, id = 0}}
        i = 0
        startTime = <optimized out>
        st = DGL::PUGL_SUCCESS
#45 DGL::puglUpdate(DGL::PuglWorld*, double) (world=0x55f0bd9265b0, timeout=<optimized out>) at src/pugl-upstream/src/x11.c:1262
        startTime = <optimized out>
        st = DGL::PUGL_SUCCESS
--Type <RET> for more, q to quit, c to continue without paging--
#46 0x000055f0b881d12c in DGL::Application::PrivateData::idle(unsigned int) (this=0x55f0bd90b9b0, timeoutInMs=timeoutInMs@entry=30) at src/ApplicationPrivateData.cpp:118
        timeoutInSeconds = <optimized out>
#47 0x000055f0b881ca48 in DGL::Application::exec(unsigned int) (this=0x55f0bd923d70, idleTimeInMs=30) at src/Application.cpp:41
#48 0x000055f0b8811421 in DISTRHO::UIExporter::exec(DGL::IdleCallback*) (cb=0x7ffd2525c740, this=0x7ffd2525c760) at ../../dpf/distrho/src/DistrhoUIInternal.hpp:224
        strBuf = "out18\000\000\000\000\000\000\024\000\000\000\000ph\232\372\003\177", '\000' <repeats 130 times>, "]\245\234\372\003\177\000\000\020\372\310\371\003\177\000\000\030\273\231\271\360U\000\000$ހ\270\360U\000\000\000\212\262\371\003\177\000\000\020\372\310\371\003\177\000\000\260"...
#49 DISTRHO::PluginJack::PluginJack(_jack_client*) (this=0x7ffd2525c740, client=<optimized out>) at ../../dpf/distrho/src/DistrhoPluginJACK.cpp:221
        strBuf = "out18\000\000\000\000\000\000\024\000\000\000\000ph\232\372\003\177", '\000' <repeats 130 times>, "]\245\234\372\003\177\000\000\020\372\310\371\003\177\000\000\030\273\231\271\360U\000\000$ހ\270\360U\000\000\000\212\262\371\003\177\000\000\020\372\310\371\003\177\000\000\260"...
#50 0x000055f0b8718da6 in main(int, char**) (argc=<optimized out>, argv=<optimized out>) at ../../dpf/distrho/src/DistrhoPluginJACK.cpp:952
        status = 0
        client = 0x55f0bcc01020
        p = 
              {<DGL::IdleCallback> = {_vptr.IdleCallback = 0x55f0bae9bc18 <vtable for DISTRHO::PluginJack+16>}, fPlugin = {fPlugin = 0x55f0bcc50750, fData = 0x55f0bcc50840, fIsActive = true, static sFallbackString = {fBuffer = 0x55f0bb0b40e8 <DISTRHO::String::_null()::sNull> "", fBufferLen = 0, fBufferAlloc = false}, static sFallbackAudioPort = {<DISTRHO::AudioPort> = {hints = 0, name = {fBuffer = 0x55f0bb0b40e8 <DISTRHO::String::_null()::sNull> "", fBufferLen = 0, fBufferAlloc = false}, symbol = {fBuffer = 0x55f0bb0b40e8 <DISTRHO::String::_null()::sNull> "", fBufferLen = 0, fBufferAlloc = false}, groupId = 4294967295}, busId = 0}, static sFallbackRanges = {def = 0, min = 0, max = 1}, static sFallbackEnumValues = {count = 0 '\000', restrictedMode = false, values = 0x0}, static sFallbackPortGroup = {<DISTRHO::PortGroup> = {name = {fBuffer = 0x55f0bb0b40e8 <DISTRHO::String::_null()::sNull> "", fBufferLen = 0, fBufferAlloc = false}, symbol = {fBuffer = 0x55f0bb0b40e8 <DISTRHO::String::_null()::sNull> "", fBufferLen = 0, fBufferAlloc = false}}, groupId = 4294967295}, leakDetector_PluginExporter = {<No data fields>}}, fUI = {ui = 0x55f0bd9bed90, uiData = 0x55f0bd923d70, leakDetector_UIExporter = {<No data fields>}}, fClient = 0x55f0bcc01020, fPortAudioIns = {0x7f03f0028ba0, 0x7f03f00292c8, 0x7f03f00299f0, 0x7f03f002a118, 0x7f03f002a840, 0x7f03f002af68, 0x55f0bdc4d260, 0x55f0bdc4d988, 0x55f0bdc4e0b0, 0x55f0bdc4e7d8, 0x55f0bdc4ef00, 0x55f0bdc4f628, 0x55f0bdc4fd50, 0x55f0bdc50478, 0x55f0bdc51900, 0x55f0bdc52028, 0x55f0bdc52750, 0x55f0bdc52e78}, fPortAudioOuts = {0x55f0bdc535a0, 0x55f0bdc53cc8, 0x55f0bdc543f0, 0x55f0bdc54b18, 0x55f0bdc57c60, 0x55f0bdc58388, 0x55f0bdc58ab0, 0x55f0bdc591d8, 0x55f0bdc59900, 0x55f0bdc5a028, 0x55f0bdc5a750, 0x55f0bdc5ae78, 0x55f0bdc5dbb0, 0x55f0bdc5e2d8, 0x55f0bdc5ea00, 0x55f0bdc5f128, 0x55f0bdc5f850, 0x55f0bdc5ff78}, fPortEventsIn = 0x55f0bdc606a0, fPortMidiOut = 0x55f0bdc60dc8, fPortMidiOutBuffer = 0x0, fTimePosition = {playing = false, frame = 0, bbt = {valid = false, bar = 0, beat = 0, tick = 0, barStartTick = 0, beatsPerBar = 0, beatType = 0, ticksPerBeat = 0, beatsPerMinute = 0}}, fLastOutputValues = 0x55f0bdbff700, fParametersChanged = 0x55f0bdc64090, fNotesRingBuffer = {<DISTRHO::RingBufferControl<DISTRHO::SmallStackBuffer>> = {_vptr.RingBufferControl = 0x55f0bae9bab8 <vtable for DISTRHO::SmallStackRingBuffer+16>, buffer = 0x7ffd2525c924, errorReading = false, errorWriting = false}, stackBuffer = {static size = 4096, head = 0, tail = 0, wrtn = 0, invalidateCommit = false, buf = '\000' <repeats 4095 times>}}}


@roberChen
Copy link
Author

so this bug seems to be related to cf, here is the related code:
https://github.com/CardinalModules/cf/blob/51506f16bb65104b5efb5294ace5ee912a9abcc9/src/PLAY.cpp#L252-L254

@falkTX
Copy link
Contributor

falkTX commented Dec 28, 2021

a backtrace, that is very useful, thanks.

I dont get this crash on my side though, on all systems I have tried.
so maybe a compiler or system specific bug.

is this on archlinux?

@roberChen
Copy link
Author

roberChen commented Dec 28, 2021

is this on archlinux?

yes, and specifically, manjaro linux, but build with SYSDEPS=false on this version.

@roberChen
Copy link
Author

and the change I've made to get the backtrace:

───────┬────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
       │ File: PKGBUILD
───────┼────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
   1   │ # Maintainer: redtide <[email protected]>
   2   │ 
   3 + │ OPTIONS+=(debug !strip)
   4 + │ 
   5   │ _pkgname="cardinal"
   6   │ pkgname="${_pkgname}-git"
   7 ~ │ pkgver=r488.3e778c9
   8   │ pkgrel=1
   9   │ pkgdesc="DPF'ied build of VCVRack, allowing it to be used as an audio plugin."
  10   │ url="https://github.com/DISTRHO/Cardinal"
  11   │ arch=("x86_64")
  12   │ license=("GPL3")
  13   │ makedepends=("git")
  14   │ depends=("jansson" "libarchive" "libgl" "libsamplerate" "libx11" "speexdsp")
  15   │ provides=("${_pkgname}")
  16   │ conflicts=("${_pkgname}")
  17   │ source=("${_pkgname}"::"git+https://github.com/DISTRHO/Cardinal")
  18   │ sha512sums=("SKIP")
  19   │ pkgver() {
  20   │     cd "${srcdir}/${_pkgname}"
  21   │     printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
  22   │ }
  23   │ prepare() {
  24   │     cd "${srcdir}/${_pkgname}"
  25   │     git submodule update --init --recursive
  26   │ }
  27   │ build() {
  28   │     cd "${srcdir}/${_pkgname}"
  29 ~ │     make PREFIX=/usr DEBUG=true
  30   │ }
  31   │ package() {
  32   │     cd "${srcdir}/${_pkgname}"
  33 ~ │     make PREFIX=/usr DESTDIR="${pkgdir}/" install
  34   │ }
───────┴────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────

and makefile of Rack:

diff --git a/plugin.mk b/plugin.mk
index 3258094f..fe66bfca 100644
--- a/plugin.mk
+++ b/plugin.mk
@@ -65,6 +65,8 @@ dist: all
        mkdir -p dist/$(SLUG)
        @# Strip and copy plugin binary
        cp $(TARGET) dist/$(SLUG)/
+
+ifeq($(DEBUG),true)
 ifdef ARCH_MAC
        $(STRIP) -S dist/$(SLUG)/$(TARGET)
        $(INSTALL_NAME_TOOL) -change libRack.dylib /tmp/Rack2/libRack.dylib dist/$(SLUG)/$(TARGET)
@@ -72,6 +74,7 @@ ifdef ARCH_MAC
 else
        $(STRIP) -s dist/$(SLUG)/$(TARGET)
 endif
+endif #debug
        @# Copy distributables
 ifdef ARCH_MAC
        rsync -rR $(DISTRIBUTABLES) dist/$(SLUG)/

@falkTX
Copy link
Contributor

falkTX commented Dec 28, 2021

you dont need to modify rack's makefiles, those are never used.

if you know a little bit of coding you could try to fix this and post a patch.
something like this should do it perhaps:

std::string fD = module ? module->fileDesc : "load sample";
std::string to_display = fD;
to_display.resize(14);

@roberChen
Copy link
Author

@falkTX I've made a pull request to fix this bug, could you merge it?

@falkTX
Copy link
Contributor

falkTX commented Dec 30, 2021

do you confirm the fix then?
we will need to send it upstream, not just in CardinalModules. but I can cherry-pick the commit(s)

@roberChen
Copy link
Author

Didn't see any crash with this fix. And I also found this bug at three different modules.

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

Successfully merging a pull request may close this issue.

2 participants