matlab crash when libqhyccd is unloaded
Opened this issue · 0 comments
EastEriq commented
Reminder, to try to stay on the safe side I unload the library only if I think that no camera is connected (https://github.com/EastEriq/LAST_QHYccd/blob/mastrolindo/%2Binst/%40QHYccd/private/releaseAndUnloadQHYlibrary.m)
I can't exactly pinpoint when this happens and when not. I suspect a delayed release of some resource, which causes a segfault if matlab is shut down too early.
Crash symptoms like (log from lipp)
10:18:41.135 [INF] [pid=913159] {inst.QHYccd} Succesfully closed "QHY600M-e69896449e35647d5"
10:18:41.177 [INF] [pid=913159] {inst.QHYccd} last QHY object destroyed, releasing library
10:18:41.199 [INF] [pid=913159] {inst.QHYccd} Released...
--------------------------------------------------------------------------------
Segmentation violation detected at 2024-01-23 10:18:41 +0000
--------------------------------------------------------------------------------
Configuration:
Crash Decoding : Disabled - No sandbox or build area path
Crash Mode : continue (default)
Default Encoding : US-ASCII
Deployed : false
GNU C Library : 2.31 stable
Graphics Driver : Unknown software
Graphics card 1 : 0x10de ( 0x10de ) 0x1d01 Version 470.223.2.0 (0-0-0)
Java Version : Java 1.8.0_202-b08 with Oracle Corporation Java HotSpot(TM) 64-Bit Server VM mixed mode
MATLAB Architecture : glnxa64
MATLAB Entitlement ID : 3913404
MATLAB Root : /usr/local/MATLAB/R2020b
MATLAB Version : 9.9.0.1467703 (R2020b)
OpenGL : software
Operating System : Ubuntu 20.04.3 LTS
Process ID : 913159
Processor ID : x86 Family 143 Model 49 Stepping 0, AuthenticAMD
Session Key : a45267d3-2d07-4331-99ad-6e93680d7378
Static TLS mitigation : Disabled: Unnecessary
Window System : No active display
Fault Count: 1
Abnormal termination:
Segmentation violation
Current Thread: 'MCR 0 interpret' id 139744428046080
Register State (from fault):
RAX = 0000000000000000 RBX = 00007f18276e8e80
RCX = 00000000ffffffff RDX = 00007f18c8fe2c68
RSP = 00007f18c8fe2540 RBP = 00007f18c8fe2bb0
RSI = ffffffffffffffff RDI = 0000000000000000
R8 = 0000000000000000 R9 = 00007f18274bddf4
R10 = 00000000ffffffff R11 = 0000000000000001
R12 = 0000000000000000 R13 = 00007f18c8fe2c68
R14 = 0000000000000000 R15 = 00007f18276e8ef0
RIP = 00007f1a43f76e0a EFL = 0000000000010286
CS = 0033 FS = 0000 GS = 0000
Stack Trace (from fault):
[ 0] 0x00007f1a43f76e0a /usr/local/MATLAB/R2020b/bin/glnxa64/libmwmst.so+00970250 _ZN7mwboost4asio6detail13epoll_reactor3runElRNS1_8op_queueINS1_19scheduler_operationEEE+00000074
[ 1] 0x00007f1a43f77e06 /usr/local/MATLAB/R2020b/bin/glnxa64/libmwmst.so+00974342 _ZN7mwboost4asio6detail9scheduler3runERNS_6system10error_codeE+00000390
[ 2] 0x00007f1a1ed80742 /usr/local/MATLAB/R2020b/bin/glnxa64/ddux/ddux_impl/mwddux_impl.so+01791810 _ZN7mwboost4asio10io_context3runEv+00000050
[ 3] 0x00007f1a4482c482 /usr/local/MATLAB/R2020b/bin/glnxa64/libmwboost_thread.so.1.70.0+00062594
[ 4] 0x00007f1a452bc609 /lib/x86_64-linux-gnu/libpthread.so.0+00034313
[ 5] 0x00007f1a44fe2163 /lib/x86_64-linux-gnu/libc.so.6+01175907 clone+00000067
** This crash report has been saved to disk as /home/ocs/matlab_crash_dump.913159-1 **