Bug 407235 - macOS : digiKam 6 crashes when quitting
Summary: macOS : digiKam 6 crashes when quitting
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Bundle-MacOS (show other bugs)
Version: 6.2.0
Platform: macOS (DMG) macOS
: NOR crash
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-05-05 13:30 UTC by Christophe14
Modified: 2019-08-26 15:17 UTC (History)
10 users (show)

See Also:
Latest Commit:
Version Fixed In: 6.3.0


Attachments
Crash report of quiting macOS 10.14.5 Mojave (85.85 KB, text/plain)
2019-06-16 08:25 UTC, Keith Yang
Details
Crash report of quiting 6.3.0-git-20190811T185852-MacOS-x86-64 on macOS 10.14.6 Mojave (87.68 KB, text/plain)
2019-08-16 14:00 UTC, Keith Yang
Details
Crash report of 2ed time quiting 6.3.0-git-20190811T185852-MacOS-x86-64 on macOS 10.14.6 Mojave (87.60 KB, text/plain)
2019-08-16 14:03 UTC, Keith Yang
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Christophe14 2019-05-05 13:30:28 UTC
SUMMARY
digiKam application version 6.1.0 is crashing on mac OS 10.12.6 just after quitting.
Apple Finder is requesting to report a crash report. 

STEPS TO REPRODUCE
1. Open digiKam
2. Close digiKam
3. 

OBSERVED RESULT
Apple Crash Windows is open.

EXPECTED RESULT


SOFTWARE/OS VERSIONS
Windows: 
macOS:10.12.6 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION

Process:               digikam [1724]
Path:                  /opt/digikam/*/digikam.app/Contents/MacOS/digikam
Identifier:            digikam
Version:               6.1.0 (6.1.0)
Code Type:             X86-64 (Native)
Parent Process:        ??? [1]
Responsible:           digikam [1724]
User ID:               502

Date/Time:             2019-05-05 15:24:52.271 +0200
OS Version:            Mac OS X 10.12.6 (16G1918)
Report Version:        12
Anonymous UUID:        7731A154-8977-F0A1-0A06-D5E8218EF53D


Time Awake Since Boot: 2800 seconds

System Integrity Protection: enabled

Crashed Thread:        0  Dispatch queue: com.apple.main-thread

Exception Type:        EXC_BAD_ACCESS (SIGSEGV)
Exception Codes:       EXC_I386_GPFLT
Exception Note:        EXC_CORPSE_NOTIFY

Termination Signal:    Segmentation fault: 11
Termination Reason:    Namespace SIGNAL, Code 0xb
Terminating Process:   exc handler [0]
Comment 1 simongcc 2019-05-10 05:44:22 UTC
Same problem in same OS +1
Comment 2 roberto 2019-05-14 11:16:44 UTC
Same problem:
Process:               digikam [3092]
Path:                  /opt/digikam/*/digikam.app/Contents/MacOS/digikam
Identifier:            digikam
Version:               6.1.0 (6.1.0)
Code Type:             X86-64 (Native)
Parent Process:        ??? [1]
Responsible:           digikam [3092]
User ID:               501

Date/Time:             2019-05-14 13:13:31.533 +0200
OS Version:            Mac OS X 10.14.4 (18E226)
Report Version:        12
Anonymous UUID:        27CD326F-9D54-42A9-BC6A-784E8F437048

Sleep/Wake UUID:       D24D79A2-24AC-4B96-AB35-A74A38720AF6

Time Awake Since Boot: 14000 seconds
Time Since Wake:       11000 seconds

System Integrity Protection: enabled

Crashed Thread:        0  Dispatch queue: com.apple.main-thread

Exception Type:        EXC_BAD_ACCESS (SIGSEGV)
Exception Codes:       EXC_I386_GPFLT
Exception Note:        EXC_CORPSE_NOTIFY

Termination Signal:    Segmentation fault: 11
Termination Reason:    Namespace SIGNAL, Code 0xb
Terminating Process:   exc handler [3092]

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
Comment 3 Maik Qualmann 2019-05-14 11:59:53 UTC
Please visit this page: https://www.digikam.org/contribute/

To get a better bugtrace for MacOS.

Maik
Comment 4 Christophe14 2019-05-15 12:30:20 UTC
OK. But where can I find the mac debug version of digiKam ?
I haven't found it on https://www.digikam.org
Comment 5 Maik Qualmann 2019-05-15 14:19:51 UTC
The digiKam version for OS X should contain debug symbol, launch digiKam in a terminal / console with the following command:

lldb /opt/digikam/Applications/KF5/digikam.app/Contents/MacOS/digikam

Maik
Comment 6 Christophe14 2019-05-15 16:24:30 UTC
Here is the log when just quitting:

2019-05-15 18:22:38.378655+0200 digikam[5349:1316418] [digikam.geoiface] ----
2019-05-15 18:22:39.010323+0200 digikam[5349:1316418] [digikam.general] Cancel Main Thread
2019-05-15 18:22:39.010386+0200 digikam[5349:1316418] [digikam.general] Cancel Main Thread
Process 5349 stopped
* thread #1, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS (code=EXC_I386_GPFLT)
    frame #0: 0x000000010002583e dyld`dyld::fastBindLazySymbol(ImageLoader**, unsigned long) + 43
dyld`dyld::fastBindLazySymbol:
->  0x10002583e <+43>: movq   0x140(%rax), %rax
    0x100025845 <+50>: movq   0x3b274(%rip), %rdx       ; dyld::gLibSystemHelpers
    0x10002584c <+57>: xorl   %ecx, %ecx
    0x10002584e <+59>: testq  %rdx, %rdx
Target 0: (digikam) stopped.
Comment 7 Christophe14 2019-05-16 12:55:10 UTC
Thanks Maik for the clarification !
Comment 8 Maik Qualmann 2019-05-16 13:39:53 UTC
There is a longer bugtrace here, but even there I do not really see the possible cause. I could imagine a problem when unloading the DPlugins.

http://digikam.1695700.n4.nabble.com/digiKam-users-macOS-10-14-5-1014-4-Crash-during-quit-of-digiKam-6-1-0-td4708540.html

Maik
Comment 9 Maik Qualmann 2019-05-16 17:30:11 UTC
Git commit c75605b83e9d395f8c7052335c7d594e6bc6823f by Maik Qualmann.
Committed on 16/05/2019 at 17:29.
Pushed by mqualmann into branch 'master'.

an attempt to fix the crash on OS X

M  +4    -3    core/app/main/digikamapp.cpp

https://invent.kde.org/kde/digikam/commit/c75605b83e9d395f8c7052335c7d594e6bc6823f
Comment 10 Geoff King 2019-05-17 21:09:00 UTC
I also have this crash on 10.13.5 and now 10.13.6. 

Looks like you are already aware, but here you go anyway.  

2019-05-17 17:06:10.646973-0400 digikam[920:27990] [digikam.general] Cancel Main Thread
2019-05-17 17:06:10.647042-0400 digikam[920:27990] [digikam.general] Cancel Main Thread
Process 920 stopped
* thread #1, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS (code=1, address=0x10f76ee4)
    frame #0: 0x000000010002552a dyld`dyld::fastBindLazySymbol(ImageLoader**, unsigned long) + 43
dyld`dyld::fastBindLazySymbol:
->  0x10002552a <+43>: movq   0x140(%rax), %rax
    0x100025531 <+50>: movq   0x48c98(%rip), %rdx       ; dyld::gLibSystemHelpers
    0x100025538 <+57>: testq  %rdx, %rdx
    0x10002553b <+60>: je     0x100025547               ; <+72>
Target 0: (digikam) stopped.
(lldb)
Comment 11 Christophe14 2019-05-18 15:31:03 UTC
Maik,
Are you in position to test your fix attempt on macOS ?

If not, and in case you would be interested and could provide a beta version with this fix included, I would be in position to test it.
Comment 12 Maik Qualmann 2019-05-18 15:34:16 UTC
Gilles creates the OS X packages on his machine. He is currently traveling, when he returns, he will build new packages.

Maik
Comment 13 Maik Qualmann 2019-05-20 06:07:35 UTC
Git commit 43af23ef461e444f647f400fe24d0f9df8a8b8c1 by Maik Qualmann.
Committed on 20/05/2019 at 06:05.
Pushed by mqualmann into branch 'master'.

next try to fix crash at end

M  +3    -3    core/app/main/digikamapp.cpp

https://invent.kde.org/kde/digikam/commit/43af23ef461e444f647f400fe24d0f9df8a8b8c1
Comment 14 Maik Qualmann 2019-05-20 20:59:40 UTC
New packages for MacOS have been created. Is the problem with the crash still to reproduce at the end?

https://files.kde.org/digikam/

Maik
Comment 15 Christophe14 2019-05-21 07:57:37 UTC
Unfortunately, the problem is still present.

Here is the Apple trace :
Process:               digikam [2075]
Path:                  /opt/digikam/*/digikam.app/Contents/MacOS/digikam
Identifier:            digikam
Version:               6.2.0 (6.2.0-git)
Code Type:             X86-64 (Native)
Parent Process:        ??? [1]
Responsible:           digikam [2075]
User ID:               502

Date/Time:             2019-05-21 09:51:55.491 +0200
OS Version:            Mac OS X 10.12.6 (16G1918)
Report Version:        12
Anonymous UUID:        7731A154-8977-F0A1-0A06-D5E8218EF53D

Sleep/Wake UUID:       29025AB9-98B3-4D40-92E2-154EB376F99F

Time Awake Since Boot: 4100 seconds

System Integrity Protection: enabled

Crashed Thread:        0  Dispatch queue: com.apple.main-thread

Exception Type:        EXC_BAD_ACCESS (SIGSEGV)
Exception Codes:       KERN_PROTECTION_FAILURE at 0x00007fff4fcca570
Exception Note:        EXC_CORPSE_NOTIFY

Termination Signal:    Segmentation fault: 11
Termination Reason:    Namespace SIGNAL, Code 0xb
Terminating Process:   exc handler [0]

VM Regions Near 0x7fff4fcca570:
    STACK GUARD            00007fff4bccb000-00007fff4f4cb000 [ 56.0M] ---/rwx SM=NUL  stack guard for thread 0
--> Stack                  00007fff4f4cb000-00007fff4fccb000 [ 8192K] rw-/rwx SM=PRV  thread 0
    Submap                 00007fff70000000-00007fff80000000 [256.0M] r--/rwx SM=SHM  machine-wide VM submap

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0   ???                           	0x00007fff4fcca570 0 + 140734532199792

Thread 1:
0   libsystem_kernel.dylib        	0x000000011f55644e __workq_kernreturn + 10
1   libsystem_pthread.dylib       	0x00007fffa9d87621 _pthread_wqthread + 1426
2   libsystem_pthread.dylib       	0x00007fffa9d8707d start_wqthread + 13

Thread 2:: com.apple.NSEventThread
0   libsystem_kernel.dylib        	0x000000011f54e34a mach_msg_trap + 10
1   libsystem_kernel.dylib        	0x000000011f54d797 mach_msg + 55
2   com.apple.CoreFoundation      	0x000000011b6097a4 __CFRunLoopServiceMachPort + 212
3   com.apple.CoreFoundation      	0x000000011b608c21 __CFRunLoopRun + 1361
4   com.apple.CoreFoundation      	0x000000011b608474 CFRunLoopRunSpecific + 420
5   com.apple.AppKit              	0x0000000115059f02 _NSEventThread + 205
6   libsystem_pthread.dylib       	0x00007fffa9d8793b _pthread_body + 180
7   libsystem_pthread.dylib       	0x00007fffa9d87887 _pthread_start + 286
8   libsystem_pthread.dylib       	0x00007fffa9d8708d thread_start + 13

Thread 3:
0   libsystem_kernel.dylib        	0x000000011f55644e __workq_kernreturn + 10
1   libsystem_pthread.dylib       	0x00007fffa9d8748e _pthread_wqthread + 1023
2   libsystem_pthread.dylib       	0x00007fffa9d8707d start_wqthread + 13

Thread 4:: QDBusConnectionManager
0   libsystem_kernel.dylib        	0x000000011f55719e poll + 10
1   org.qt-project.QtCore         	0x00000001194dcaf4 qt_safe_poll(pollfd*, unsigned int, timespec const*) + 579
2   org.qt-project.QtCore         	0x00000001194dd968 QEventDispatcherUNIX::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) + 532
3   org.qt-project.QtCore         	0x0000000119498940 QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) + 318
4   org.qt-project.QtCore         	0x00000001193480b0 QThread::exec() + 108
5   org.qt-project.QtDBus         	0x000000011729c5e5 0x117299000 + 13797
6   org.qt-project.QtCore         	0x000000011934f8f2 0x119329000 + 157938
7   libsystem_pthread.dylib       	0x00007fffa9d8793b _pthread_body + 180
8   libsystem_pthread.dylib       	0x00007fffa9d87887 _pthread_start + 286
9   libsystem_pthread.dylib       	0x00007fffa9d8708d thread_start + 13

Thread 5:: QThread
0   libsystem_kernel.dylib        	0x000000011f555bf2 __psynch_cvwait + 10
1   libsystem_pthread.dylib       	0x00007fffa9d887fa _pthread_cond_wait + 712
2   org.qt-project.QtCore         	0x0000000119350bb1 0x119329000 + 162737
3   org.qt-project.QtCore         	0x0000000119350b15 QWaitCondition::wait(QMutex*, unsigned long) + 97
4   libdigikamcore.6.2.0.dylib    	0x00000001117ff045 Digikam::ParkingThread::run() + 165
5   org.qt-project.QtCore         	0x000000011934f8f2 0x119329000 + 157938
6   libsystem_pthread.dylib       	0x00007fffa9d8793b _pthread_body + 180
7   libsystem_pthread.dylib       	0x00007fffa9d87887 _pthread_start + 286
8   libsystem_pthread.dylib       	0x00007fffa9d8708d thread_start + 13

Thread 6:: JavaScriptCore::BlockFree
0   libsystem_kernel.dylib        	0x000000011f555bf2 __psynch_cvwait + 10
1   libsystem_pthread.dylib       	0x00007fffa9d887fa _pthread_cond_wait + 712
2   org.qt-project.QtWebKit       	0x00000001186e8e47 0x1179aa000 + 13889095
3   org.qt-project.QtWebKit       	0x00000001188b3f86 0x1179aa000 + 15769478
4   libsystem_pthread.dylib       	0x00007fffa9d8793b _pthread_body + 180
5   libsystem_pthread.dylib       	0x00007fffa9d87887 _pthread_start + 286
6   libsystem_pthread.dylib       	0x00007fffa9d8708d thread_start + 13

Thread 7:: JavaScriptCore::Marking
0   libsystem_kernel.dylib        	0x000000011f555bf2 __psynch_cvwait + 10
1   libsystem_pthread.dylib       	0x00007fffa9d887fa _pthread_cond_wait + 712
2   org.qt-project.QtWebKit       	0x00000001186e9a76 0x1179aa000 + 13892214
3   org.qt-project.QtWebKit       	0x00000001186e9b35 0x1179aa000 + 13892405
4   org.qt-project.QtWebKit       	0x00000001188b3f86 0x1179aa000 + 15769478
5   libsystem_pthread.dylib       	0x00007fffa9d8793b _pthread_body + 180
6   libsystem_pthread.dylib       	0x00007fffa9d87887 _pthread_start + 286
7   libsystem_pthread.dylib       	0x00007fffa9d8708d thread_start + 13

Thread 8:: JavaScriptCore::Marking
0   libsystem_kernel.dylib        	0x000000011f555bf2 __psynch_cvwait + 10
1   libsystem_pthread.dylib       	0x00007fffa9d887fa _pthread_cond_wait + 712
2   org.qt-project.QtWebKit       	0x00000001186e9a76 0x1179aa000 + 13892214
3   org.qt-project.QtWebKit       	0x00000001186e9b35 0x1179aa000 + 13892405
4   org.qt-project.QtWebKit       	0x00000001188b3f86 0x1179aa000 + 15769478
5   libsystem_pthread.dylib       	0x00007fffa9d8793b _pthread_body + 180
6   libsystem_pthread.dylib       	0x00007fffa9d87887 _pthread_start + 286
7   libsystem_pthread.dylib       	0x00007fffa9d8708d thread_start + 13

Thread 9:: JavaScriptCore::Marking
0   libsystem_kernel.dylib        	0x000000011f555bf2 __psynch_cvwait + 10
1   libsystem_pthread.dylib       	0x00007fffa9d887fa _pthread_cond_wait + 712
2   org.qt-project.QtWebKit       	0x00000001186e9a76 0x1179aa000 + 13892214
3   org.qt-project.QtWebKit       	0x00000001186e9b35 0x1179aa000 + 13892405
4   org.qt-project.QtWebKit       	0x00000001188b3f86 0x1179aa000 + 15769478
5   libsystem_pthread.dylib       	0x00007fffa9d8793b _pthread_body + 180
6   libsystem_pthread.dylib       	0x00007fffa9d87887 _pthread_start + 286
7   libsystem_pthread.dylib       	0x00007fffa9d8708d thread_start + 13

Thread 10:: JavaScriptCore::Marking
0   libsystem_kernel.dylib        	0x000000011f555bf2 __psynch_cvwait + 10
1   libsystem_pthread.dylib       	0x00007fffa9d887fa _pthread_cond_wait + 712
2   org.qt-project.QtWebKit       	0x00000001186e9a76 0x1179aa000 + 13892214
3   org.qt-project.QtWebKit       	0x00000001186e9b35 0x1179aa000 + 13892405
4   org.qt-project.QtWebKit       	0x00000001188b3f86 0x1179aa000 + 15769478
5   libsystem_pthread.dylib       	0x00007fffa9d8793b _pthread_body + 180
6   libsystem_pthread.dylib       	0x00007fffa9d87887 _pthread_start + 286
7   libsystem_pthread.dylib       	0x00007fffa9d8708d thread_start + 13

Thread 11:: JavaScriptCore::Marking
0   libsystem_kernel.dylib        	0x000000011f555bf2 __psynch_cvwait + 10
1   libsystem_pthread.dylib       	0x00007fffa9d887fa _pthread_cond_wait + 712
2   org.qt-project.QtWebKit       	0x00000001186e9a76 0x1179aa000 + 13892214
3   org.qt-project.QtWebKit       	0x00000001186e9b35 0x1179aa000 + 13892405
4   org.qt-project.QtWebKit       	0x00000001188b3f86 0x1179aa000 + 15769478
5   libsystem_pthread.dylib       	0x00007fffa9d8793b _pthread_body + 180
6   libsystem_pthread.dylib       	0x00007fffa9d87887 _pthread_start + 286
7   libsystem_pthread.dylib       	0x00007fffa9d8708d thread_start + 13

Thread 12:: JavaScriptCore::Marking
0   libsystem_kernel.dylib        	0x000000011f555bf2 __psynch_cvwait + 10
1   libsystem_pthread.dylib       	0x00007fffa9d887fa _pthread_cond_wait + 712
2   org.qt-project.QtWebKit       	0x00000001186e9a76 0x1179aa000 + 13892214
3   org.qt-project.QtWebKit       	0x00000001186e9b35 0x1179aa000 + 13892405
4   org.qt-project.QtWebKit       	0x00000001188b3f86 0x1179aa000 + 15769478
5   libsystem_pthread.dylib       	0x00007fffa9d8793b _pthread_body + 180
6   libsystem_pthread.dylib       	0x00007fffa9d87887 _pthread_start + 286
7   libsystem_pthread.dylib       	0x00007fffa9d8708d thread_start + 13

Thread 13:
0   libsystem_kernel.dylib        	0x000000011f55644e __workq_kernreturn + 10
1   libsystem_pthread.dylib       	0x00007fffa9d87621 _pthread_wqthread + 1426
2   libsystem_pthread.dylib       	0x00007fffa9d8707d start_wqthread + 13

Thread 14:: com.apple.CFSocket.private
0   libsystem_kernel.dylib        	0x000000011f555eb6 __select + 10
1   com.apple.CoreFoundation      	0x000000011b644899 __CFSocketManager + 729
2   libsystem_pthread.dylib       	0x00007fffa9d8793b _pthread_body + 180
3   libsystem_pthread.dylib       	0x00007fffa9d87887 _pthread_start + 286
4   libsystem_pthread.dylib       	0x00007fffa9d8708d thread_start + 13

Thread 15:: Thread (pooled)
0   libsystem_kernel.dylib        	0x000000011f555bf2 __psynch_cvwait + 10
1   libsystem_pthread.dylib       	0x00007fffa9d887fa _pthread_cond_wait + 712
2   org.qt-project.QtCore         	0x0000000119350ba4 0x119329000 + 162724
3   org.qt-project.QtCore         	0x0000000119350b15 QWaitCondition::wait(QMutex*, unsigned long) + 97
4   org.qt-project.QtCore         	0x0000000119348bb6 0x119329000 + 129974
5   org.qt-project.QtCore         	0x000000011934f8f2 0x119329000 + 157938
6   libsystem_pthread.dylib       	0x00007fffa9d8793b _pthread_body + 180
7   libsystem_pthread.dylib       	0x00007fffa9d87887 _pthread_start + 286
8   libsystem_pthread.dylib       	0x00007fffa9d8708d thread_start + 13

Thread 16:
0   libsystem_pthread.dylib       	0x00007fffa9d87070 start_wqthread + 0

Thread 17:
0   libsystem_kernel.dylib        	0x000000011f55644e __workq_kernreturn + 10
1   libsystem_pthread.dylib       	0x00007fffa9d87621 _pthread_wqthread + 1426
2   libsystem_pthread.dylib       	0x00007fffa9d8707d start_wqthread + 13

Thread 18:
0   libsystem_pthread.dylib       	0x00007fffa9d87070 start_wqthread + 0
1   ???                           	0x0000000112b45000 0 + 4608774144

Thread 19:
0   libsystem_kernel.dylib        	0x000000011f55644e __workq_kernreturn + 10
1   libsystem_pthread.dylib       	0x00007fffa9d87621 _pthread_wqthread + 1426
2   libsystem_pthread.dylib       	0x00007fffa9d8707d start_wqthread + 13

Thread 20:
0   libsystem_kernel.dylib        	0x000000011f55644e __workq_kernreturn + 10
1   libsystem_pthread.dylib       	0x00007fffa9d87621 _pthread_wqthread + 1426
2   libsystem_pthread.dylib       	0x00007fffa9d8707d start_wqthread + 13

Thread 0 crashed with X86 Thread State (64-bit):
  rax: 0x000000000000001d  rbx: 0x00000001305ca008  rcx: 0x0000000000000000  rdx: 0x0000000000000000
  rdi: 0x0000000000000002  rsi: 0x00007fff4fcca400  rbp: 0x00007fff4fcca550  rsp: 0x00007fff4fcca558
   r8: 0x000000011f510139   r9: 0x00007fff4fcca8c0  r10: 0x00007fff4fcca41d  r11: 0x0000000000000206
  r12: 0x00007f9bba2f5800  r13: 0x0000000000000002  r14: 0x000000000000067c  r15: 0x00006180000dfb28
  rip: 0x00007fff4fcca570  rfl: 0x0000000000010202  cr2: 0x00007fff4fcca570
  
Logical CPU:     0
Error Code:      0x00000015
Trap Number:     14
Comment 16 Christophe14 2019-05-21 08:03:57 UTC
And the debug trace when quitting :
019-05-21 10:00:08.201231+0200 digikam[2253:229572] [digikam.geoiface] ----
2019-05-21 10:00:08.913188+0200 digikam[2253:229572] [digikam.general] Cancel Main Thread
2019-05-21 10:00:08.913254+0200 digikam[2253:229572] [digikam.general] Cancel Main Thread
Process 2253 stopped
* thread #1, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS (code=1, address=0x176)
    frame #0: 0x000000010002583e dyld`dyld::fastBindLazySymbol(ImageLoader**, unsigned long) + 43
dyld`dyld::fastBindLazySymbol:
->  0x10002583e <+43>: movq   0x140(%rax), %rax
    0x100025845 <+50>: movq   0x3b274(%rip), %rdx       ; dyld::gLibSystemHelpers
    0x10002584c <+57>: xorl   %ecx, %ecx
    0x10002584e <+59>: testq  %rdx, %rdx
Target 0: (digikam) stopped.
Comment 17 Maik Qualmann 2019-05-21 10:27:22 UTC
You can find some crashing with "fastBindLazySymbol()" via Google. Some solutions refer to the fact that the application is not compiled for the Mac version. In the other threads there are still calls from QtWebKit, I think we are using an updated version in digikam-6.1.0.

Maik
Comment 18 caulier.gilles 2019-05-21 17:24:15 UTC
You is right Maik. For the MacOS support we swithch from Qt 5.7 to Qt 5.11.3 as for Linux (Windows use Qt 5.12.1)
Comment 19 caulier.gilles 2019-05-21 18:50:17 UTC
Maik, 

The reason to upgrade Qt from 5.7 to 5.11.3 is to support the new KF5 which requires Qt 5.10 since 5.56. We use now KF5.57 (and last one is just out: 5.58).

Upgrading Qt as a main influence on minimal MacOS support. Look my note here :

https://cgit.kde.org/digikam.git/tree/project/bundles/macports/config.sh#n18

This is a corresponding backward compatibility with MacOS and Qt that i have experimented. This is not really what Qt team give, because we don't compaile the whole Qt for digiKam (for ex QML is not necessary).

So the values differ a we can have a large spectre of compatibility, but as you can see, we have switched from MacOS 10.8 to 10.11.

I tried with lesser MacOS version with Qt 5.11.3, but there are few linking problems, not resolved by Macports project with patches. I already reported this problem in Macports bugzilla, but the response is clear : there are not enough developers to increase the MacOS backward compatibility with more recent Qt5.

Voilà

Gilles
Comment 20 Christophe14 2019-05-27 12:22:56 UTC
Hi Gilles,

If I understand correctly, we will have to leave with this issue for a long time :-(

Kind regards

Christophe
Comment 21 caulier.gilles 2019-05-27 13:35:30 UTC
Well, this want mean to ugrde your MacOS system to 10.11.

Qt team support not well the backwoard compatibility with MacOS in new Qt version. A possible olution is to insist to MAcports team to improve the backward compatibility of Qt, but i know already the response.

What's the problem to upgrade to 10.11 ?

Best

Gilles Caulier
Comment 22 Christophe14 2019-05-27 16:32:49 UTC
Gilles,

I think there is a misunderstanding.
We are reporting this issue on mac OS 10.12, 10.13 and 10.14.
We (at least I) will not downgrade to 10.11 which is no more receiving Security Updates from Apple...

Christophe
Comment 23 caulier.gilles 2019-05-27 18:06:55 UTC
Ah. It's completely different.

When i said MacOS 10.11, it's for backward compatibilty. Of course more recent MacOS are supported.

So i will recreate the macports installation from scratch. I have also to update the XCode compiler to the last version (it still on the pipe since few months).

Let's me few days to update all and to re-init the compilation chain, compile all code (at least 3/4 hours) and generate the PKG installer...

Gilles Caulier
Comment 24 caulier.gilles 2019-05-28 03:43:59 UTC
I now installed the last Xcode, the 10.11 SDK for backwaed compatibility and start the digiKam PKG compilation from scratch. My MacBook pro  is now running at 400% for a while. Please wait (and i hope that all Macports will compile fine until end).

Gilles Caulier
Comment 25 caulier.gilles 2019-05-28 17:11:44 UTC
Progress : Macports is now compiled and installed with all dependencies required by digiKam. This take 5 hours under my Macbook pro 2012 8 cores 8Gb of RAM + SSD 1 Tb

Now, I will install KF5 + digiKam. Last stage is to build the PKG. this will take 3 hours to see a new MacOS PKG available in weekly build repository.

Gilles Caulier
Comment 26 caulier.gilles 2019-05-28 19:03:20 UTC
digiKam do not link with new XCode in MetadataEdit plugin :

[ 62%] Building CXX object core/dplugins/generic/metadata/metadataedit/CMakeFiles/Generic_MetadataEdit_Plugin.dir/xmp/xmporigin.cpp.o
warning: unknown warning option '-Wno-deprecated-copy'; did you mean '-Wno-deprecated'? [-Wunknown-warning-option]
1 warning generated.
[ 62%] Linking CXX shared module Generic_SendByMail_Plugin.so
1 warning generated.
[ 62%] Building CXX object core/dplugins/generic/metadata/metadataedit/CMakeFiles/Generic_MetadataEdit_Plugin.dir/xmp/xmpcredits.cpp.o
warning: unknown warning option '-Wno-deprecated-copy'; did you mean '-Wno-deprecated'? [-Wunknown-warning-option]
Undefined symbols for architecture x86_64:
  "DIGIKAM_DPLUGIN_GENERIC_LOG()", referenced from:
      DigikamGenericSendByMailPlugin::ImageResizeJob::imageResize(DigikamGenericSendByMailPlugin::MailSettings*, QUrl const&, QString const&, QString&) in imageresizejob.cpp.o
      DigikamGenericSendByMailPlugin::MailProcess::slotFinishedResize(QUrl const&, QUrl const&, int) in mailprocess.cpp.o
      DigikamGenericSendByMailPlugin::MailProcess::buildPropertiesFile() in mailprocess.cpp.o
      DigikamGenericSendByMailPlugin::MailProcess::invokeMailAgent() in mailprocess.cpp.o
      DigikamGenericSendByMailPlugin::MailProcess::divideEmails() in mailprocess.cpp.o
      DigikamGenericSendByMailPlugin::MailProcess::invokeMailAgentError(QString const&, QStringList const&) in mailprocess.cpp.o
      DigikamGenericSendByMailPlugin::MailProcess::invokeMailAgentDone(QString const&, QStringList const&) in mailprocess.cpp.o
      ...
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [core/dplugins/generic/tools/sendbymail/Generic_SendByMail_Plugin.so] Error 1
make[1]: *** [core/dplugins/generic/tools/sendbymail/CMakeFiles/Generic_SendByMail_Plugin.dir/all] Error 2
[ 62%] Building CXX object core/dplugins/generic/metadata/metadataedit/CMakeFiles/Generic_MetadataEdit_Plugin.

Gilles
Comment 27 Maik Qualmann 2019-05-28 19:13:04 UTC
Git commit fb1e5217f2fc275623860f72e94204cf533a548c by Maik Qualmann.
Committed on 28/05/2019 at 19:11.
Pushed by mqualmann into branch 'master'.

remove -Wno-deprecated-copy

M  +1    -1    core/CMakeLists.txt

https://invent.kde.org/kde/digikam/commit/fb1e5217f2fc275623860f72e94204cf533a548c
Comment 28 Maik Qualmann 2019-05-28 19:14:20 UTC
That was my mistake, I have to make the compiler option dependent on the compiler and version. Try again...

Maik
Comment 30 Maik Qualmann 2019-05-28 19:42:48 UTC
Ok, I see now that the process was already 62% and the unknown compiler option has only been treated as a warning.

Maik
Comment 31 caulier.gilles 2019-05-28 20:51:50 UTC
yes, but i's not enough :

/opt/digikam/libexec/qt5/lib/QtWidgets.framework/Headers/qabstractitemview.h:349:10: note: overridden virtual function is here
    bool eventFilter(QObject *object, QEvent *event) override;
         ^
In file included from /Users/gilles/dktemp/digikam-master/core/app/views/tableview/tableview_treeview.cpp:23:
/Users/gilles/dktemp/digikam-master/core/app/views/tableview/tableview_treeview.h:70:42: warning: 'dragDropHandler' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
    virtual AbstractItemDragDropHandler* dragDropHandler() const;
                                         ^
/Users/gilles/dktemp/digikam-master/core/libs/widgets/common/dragdropimplementations.h:119:42: note: overridden virtual function is here
    virtual AbstractItemDragDropHandler* dragDropHandler() const = 0;
                                         ^
In file included from /Users/gilles/dktemp/digikam-master/core/app/views/tableview/tableview_treeview.cpp:23:
/Users/gilles/dktemp/digikam-master/core/app/views/tableview/tableview_treeview.h:71:25: warning: 'mapIndexForDragDrop' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
    virtual QModelIndex mapIndexForDragDrop(const QModelIndex& index) const;
                        ^
/Users/gilles/dktemp/digikam-master/core/libs/widgets/common/dragdropimplementations.h:125:25: note: overridden virtual function is here
    virtual QModelIndex mapIndexForDragDrop(const QModelIndex& index) const = 0;
                        ^
In file included from /Users/gilles/dktemp/digikam-master/core/app/views/tableview/tableview_treeview.cpp:23:
/Users/gilles/dktemp/digikam-master/core/app/views/tableview/tableview_treeview.h:72:25: warning: 'pixmapForDrag' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
    virtual QPixmap     pixmapForDrag(const QList<QModelIndex>& indexes) const;
                        ^
/Users/gilles/dktemp/digikam-master/core/libs/widgets/common/dragdropimplementations.h:130:25: note: overridden virtual function is here
    virtual QPixmap     pixmapForDrag(const QList<QModelIndex>& indexes) const = 0;
                        ^
In file included from /Users/gilles/dktemp/digikam-master/core/app/views/tableview/tableview_treeview.cpp:23:
/Users/gilles/dktemp/digikam-master/core/app/views/tableview/tableview_treeview.h:73:18: warning: 'wheelEvent' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
    virtual void wheelEvent(QWheelEvent* event);
                 ^
/opt/digikam/libexec/qt5/lib/QtWidgets.framework/Headers/qabstractscrollarea.h:120:10: note: overridden virtual function is here
    void wheelEvent(QWheelEvent *) override;
         ^
In file included from /Users/gilles/dktemp/digikam-master/core/app/views/tableview/tableview_treeview.cpp:23:
/Users/gilles/dktemp/digikam-master/core/app/views/tableview/tableview_treeview.h:75:18: warning: 'hasHiddenGroupedImages' overrides a member function but is not marked 'override' [-Winconsistent-missing-override]
    virtual bool hasHiddenGroupedImages(const ItemInfo& info) const;
                 ^
/Users/gilles/dktemp/digikam-master/core/app/items/utils/groupingviewimplementation.h:48:19: note: overridden virtual function is here
    virtual bool  hasHiddenGroupedImages(const ItemInfo&) const
                  ^
[ 59%] Automatic MOC for target Editor_ShearTool_Plugin
[ 59%] Built target Editor_ShearTool_Plugin_autogen
[ 59%] Building CXX object core/app/CMakeFiles/digikamgui_src.dir/views/tableview/tableview_column_geo.cpp.o
6 warnings generated.
[ 59%] Building CXX object core/app/CMakeFiles/digikamgui_src.dir/views/tableview/tableview_column_digikam.cpp.o
[ 59%] Automatic MOC for target showfoto
[ 59%] Built target showfoto_autogen
Scanning dependencies of target digikamdatabase
[ 59%] Building CXX object core/libs/database/CMakeFiles/digikamdatabase.dir/digikamdatabase_autogen/mocs_compilation.cpp.o
5 warnings generated.
[ 59%] Linking CXX shared library libdigikamdatabase.dylib
Undefined symbols for architecture x86_64:
  "DIGIKAM_DBJOB_LOG()", referenced from:
      Digikam::SearchesJob::run() in dbjob.cpp.o
  "DIGIKAM_COREDB_LOG()", referenced from:
      Digikam::CoreDbPrivilegesChecker::checkPriv(Digikam::CoreDbBackend&, QString const&) in coredbchecker.cpp.o
      Digikam::CoreDbCopyManager::copyTable(Digikam::CoreDbBackend&, QString const&, Digikam::CoreDbBackend&, QString const&) in coredbcopymanager.cpp.o
      Digikam::CoreDbSchemaUpdater::update() in coredbschemaupdater.cpp.o
      Digikam::CoreDbSchemaUpdater::startUpdates() in coredbschemaupdater.cpp.o
      Digikam::CoreDbSchemaUpdater::makeUpdates() in coredbschemaupdater.cpp.o
      Digikam::CoreDbSchemaUpdater::endWrapSchemaUpdateStep(bool, QString const&) in coredbschemaupdater.cpp.o
      Digikam::CoreDbSchemaUpdater::updateV4toV7() in coredbschemaupdater.cpp.o
      ...
  "DIGIKAM_GENERAL_LOG()", referenced from:
      Digikam::HaarIface::findDuplicatesInAlbumsAndTags(QList<int> const&, QList<int> const&, Digikam::HaarIface::AlbumTagRelation, double, double, Digikam::HaarIface::DuplicatesSearchRestrictions, Digikam::HaarProgressObserver*) in haariface.cpp.o
      Digikam::ItemModel::Private::isValid(QModelIndex const&) in itemmodel.cpp.o
      Digikam::ItemModel::ensureHasItemInfos(QList<Digikam::ItemInfo> const&, QList<QVariant> const&) in itemmodel.cpp.o
      Digikam::ItemModel::Private::extraValueValid(QModelIndex const&) in itemmodel.cpp.o
  "DIGIKAM_DATABASE_LOG()", referenced from:
      Digikam::CollectionScanner::completeScan() in collectionscanner_scan.cpp.o
      Digikam::CollectionScanner::scanAlbum(Digikam::CollectionLocation const&, QString const&) in collectionscanner_scan.cpp.o
      Digikam::CollectionScanner::completeHistoryScanning() in collectionscanner_scan.cpp.o
      Digikam::CollectionScanner::partialScan(QString const&, QString const&) in collectionscanner_scan.cpp.o
      Digikam::CollectionScanner::scanFile(QString const&, QString const&, QString const&, Digikam::CollectionScanner::FileScanMode) in collectionscanner_scan.cpp.o
      Digikam::CollectionScanner::itemsWereRemoved(QList<long long> const&) in collectionscanner_utils.cpp.o
      Digikam::CollectionScanner::copyFileProperties(Digikam::ItemInfo const&, Digikam::ItemInfo const&) in collectionscanner_utils.cpp.o
      ...
  "DIGIKAM_SIMILARITYDB_LOG()", referenced from:
      Digikam::SimilarityDb::getSetting(QString const&) in similaritydb.cpp.o
      Digikam::SimilarityDb::getLegacySetting(QString const&) in similaritydb.cpp.o
      Digikam::SimilarityDb::getImageSimilarity(long long, long long, Digikam::FuzzyAlgorithm) in similaritydb.cpp.o
      Digikam::SimilarityDbSchemaUpdater::startUpdates() in similaritydbschemaupdater.cpp.o
      Digikam::SimilarityDbAccess::checkReadyForUse(Digikam::InitializationObserver*) in similaritydbaccess.cpp.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [core/libs/database/libdigikamdatabase.6.2.0.dylib] Error 1
make[1]: *** [core/libs/database/CMakeFiles/digikamdatabase.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 59%] Building CXX object core/app/CMakeFiles/digikamgui_src.dir/views/tableview/tableview_column_item.cpp.o
[ 59%] Building CXX object core/app/CMakeFiles/digikamgui_src.dir/views/tableview/tableview_column_photo.cpp.o
[ 59%] Building CXX object core/app/CMakeFiles/digikamgui_src.dir/views/tableview/tableview_column_thumbnail.cpp.o
[ 59%] Building CXX object core/app/CMakeFiles/digikamgui_src.dir/views/tableview/tableview_columnfactory.cpp.o
[ 59%] Building CXX object core/app/CMakeFiles/digikamgui_src.dir/views/tableview/tableview_selection_model_syncer.cpp.o
[ 59%] Building CXX object core/app/CMakeFiles/digikamgui_src.dir/views/stack/welcomepageview.cpp.o
[ 59%] Building CXX object core/app/CMakeFiles/digikamgui_src.dir/views/stack/itemiconview.cpp.o
[ 59%] Building CXX object core/app/CMakeFiles/digikamgui_src.dir/views/stack/trashview.cpp.o
[ 59%] Building CXX object core/app/CMakeFiles/digikamgui_src.dir/views/stack/stackedview.cpp.o
...

Remember that Xcode use CLang in background. I suspose that you can reproduce the problem if you install CLang compiler under Linux and you switch from GCC to CLang before to configure and compile digiKam.

Gilles
Comment 32 caulier.gilles 2019-05-28 20:52:56 UTC
This is the CLang version from XCode :

bash-3.2$ clang --version
Apple LLVM version 10.0.1 (clang-1001.0.46.4)
Target: x86_64-apple-darwin18.6.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
bash-3.2$ 

Gilles
Comment 33 Maik Qualmann 2019-05-28 21:06:41 UTC
I will try the days CLANG.
If I understand correctly, there is a problem with the debug macros, but why?

Maik
Comment 34 caulier.gilles 2019-05-29 03:13:14 UTC
Maik,

It was a false compilation error in fact. The PKG build script use a git cache to speed up and of course the build directory compiled with older XCode from digiKam core was not cleaned.

All compile fine now, but CLang generate one million of warnings. This must be fixed ain all case.

Updated 6.2.0 pre release PKG will be online in few minutes :

https://files.kde.org/digikam/

Gilles Caulier
Comment 35 caulier.gilles 2019-05-30 10:40:12 UTC
Christophe,

The new 6.2.0 PKG bundle is now available for testing, please give us a fresh feedback about your crash problem on your Mac

Thanks in advance

Gilles Caulier
Comment 36 Christophe14 2019-05-30 13:39:54 UTC
Hi Gilles,

Thanks for creating a new version.

As I am currently away from my Mac, I will only be in position to perform the test starting Tuesday next week.

Kind regards.
Comment 37 Geoff King 2019-05-31 00:37:58 UTC
Hello, 
I tried this new version (digiKam-6.2.0-git-20190529T050933-MacOS-x86-64)and still have a crash upon exiting.   

Process:               digikam [3154]
Path:                  /opt/digikam/*/digikam.app/Contents/MacOS/digikam
Identifier:            digikam
Version:               6.2.0 (6.2.0-git)
Code Type:             X86-64 (Native)
Parent Process:        ??? [1]
Responsible:           digikam [3154]
User ID:               501

Date/Time:             2019-05-30 20:22:34.038 -0400
OS Version:            Mac OS X 10.13.6 (17G7024)
Report Version:        12
Anonymous UUID:        91EEEDC9-4C02-F1C6-D65A-0E5D7045A6AD

Sleep/Wake UUID:       36E35936-B8B1-4758-9759-80F569BC793E

Time Awake Since Boot: 30000 seconds
Time Since Wake:       99 seconds

System Integrity Protection: enabled

Crashed Thread:        0  Dispatch queue: com.apple.main-thread

Exception Type:        EXC_BAD_ACCESS (SIGSEGV)
Exception Codes:       KERN_PROTECTION_FAILURE at 0x00007ffee87204b0
Exception Note:        EXC_CORPSE_NOTIFY

Termination Signal:    Segmentation fault: 11
Termination Reason:    Namespace SIGNAL, Code 0xb
Terminating Process:   exc handler [0]

VM Regions Near 0x7ffee87204b0:
    STACK GUARD            00007ffee4721000-00007ffee7f21000 [ 56.0M] ---/rwx SM=NUL  stack guard for thread 0
--> Stack                  00007ffee7f21000-00007ffee8721000 [ 8192K] rw-/rwx SM=PRV  thread 0
    Submap                 00007fff00000000-00007fff80000000 [  2.0G] r--/rwx SM=SHM  machine-wide VM submap

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0   ???                           	0x00007ffee87204b0 0 + 140732798207152
Comment 38 Maik Qualmann 2019-06-06 17:54:20 UTC
Git commit cfcbe04933b0e436b9a31570a9c4bbd606025a20 by Maik Qualmann.
Committed on 06/06/2019 at 17:53.
Pushed by mqualmann into branch 'master'.

next try to fix crash at end

M  +2    -0    core/libs/dplugins/setup/dpluginloader.cpp

https://invent.kde.org/kde/digikam/commit/cfcbe04933b0e436b9a31570a9c4bbd606025a20
Comment 39 Maik Qualmann 2019-06-10 20:37:44 UTC
*** Bug 408549 has been marked as a duplicate of this bug. ***
Comment 40 Maik Qualmann 2019-06-10 21:13:06 UTC
I think aloud:

I see QDBus entries, although we compile without QDbus.
And many QtWebKit entries...

Maik
Comment 41 caulier.gilles 2019-06-11 07:11:05 UTC
Maik,

Yes under MacOS, QtWebkit still used. Perhaps it's better now to switch to QtWebEngine now under MacOS.

Gilles
Comment 42 Keith Yang 2019-06-16 08:25:34 UTC
Created attachment 120909 [details]
Crash report of quiting macOS 10.14.5 Mojave

Double confirmed on latest 6.2.0 build.
Comment 43 caulier.gilles 2019-07-27 15:59:14 UTC
Please test with 6.2.0 pre-release bundles available here :

https://files.kde.org/digikam/

Thanks in advance

Gilles Caulier
Comment 44 Geoff King 2019-07-28 02:39:10 UTC
I can confirm it still crashes upon close using 6.2-pre (Build date: Jul 25 2019) on Mojave.
Comment 45 caulier.gilles 2019-08-01 08:15:19 UTC
Yes, i can confirm with 6.2.0 release and with and upgrade of last MacOS and XCode, i can see where application stop to work.

In fact it happen when BQM tool instances are deleted from memory. Look the first entries from this backtrace:

Process:               digikam [1025]
Path:                  /opt/digikam/*/digikam.app/Contents/MacOS/digikam
Identifier:            digikam
Version:               6.2.0 (6.2.0)
Code Type:             X86-64 (Native)
Parent Process:        ??? [1]
Responsible:           digikam [1025]
User ID:               501

Date/Time:             2019-08-01 10:08:41.358 +0200
OS Version:            Mac OS X 10.14.6 (18G84)
Report Version:        12
Anonymous UUID:        070280B9-577B-F1B8-0545-8D7E1B44173A


Time Awake Since Boot: 11000 seconds

System Integrity Protection: enabled

Crashed Thread:        0  Dispatch queue: com.apple.main-thread

Exception Type:        EXC_BAD_ACCESS (SIGSEGV)
Exception Codes:       EXC_I386_GPFLT
Exception Note:        EXC_CORPSE_NOTIFY

Termination Signal:    Segmentation fault: 11
Termination Reason:    Namespace SIGNAL, Code 0xb
Terminating Process:   exc handler [1025]

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0   dyld                          	0x000000011e690b70 dyld::fastBindLazySymbol(ImageLoader**, unsigned long) + 80
1   libdyld.dylib                 	0x00007fff6366b32e dyld_stub_binder + 282
2   ???                           	0x0000000123b4c008 0 + 4894015496
3   ???                           	0x0000000123b492b5 0 + 4894003893
4   ???                           	0x0000000123b492d9 0 + 4894003929
5   org.qt-project.QtCore         	0x000000011789aa1d QObjectPrivate::deleteChildren() + 107
6   org.qt-project.QtCore         	0x000000011789a83e QObject::~QObject() + 1320
7   libdigikamgui.6.2.0.dylib     	0x000000010fc5f112 Digikam::BatchToolsFactory::~BatchToolsFactory() + 82
8   libdigikamgui.6.2.0.dylib     	0x000000010fc5f155 Digikam::BatchToolsFactory::~BatchToolsFactory() + 21
9   libdigikamgui.6.2.0.dylib     	0x000000010fc5fb65 Digikam::BatchToolsFactoryCreator::~BatchToolsFactoryCreator() + 21
10  libdigikamgui.6.2.0.dylib     	0x000000010fc5fb45 Digikam::BatchToolsFactoryCreator::~BatchToolsFactoryCreator() + 21
11  libdigikamgui.6.2.0.dylib     	0x000000010fc5fb0a Digikam::(anonymous namespace)::Q_QGS_batchToolsManagerCreator::innerFunction()::Cleanup::~Cleanup() + 42
12  libdigikamgui.6.2.0.dylib     	0x000000010fc5fab5 Digikam::(anonymous namespace)::Q_QGS_batchToolsManagerCreator::innerFunction()::Cleanup::~Cleanup() + 21
13  libsystem_c.dylib             	0x00007fff637253cf __cxa_finalize_ranges + 319
14  libsystem_c.dylib             	0x00007fff637256b3 exit + 55
15  libdyld.dylib                 	0x00007fff6367f3dc start + 8
Comment 46 Maik Qualmann 2019-08-01 10:18:11 UTC
Git commit 30b6acb3ca97789d05ae21a0bf1fe44249d52418 by Maik Qualmann.
Committed on 01/08/2019 at 10:17.
Pushed by mqualmann into branch 'master'.

try to fix crash under OSX

M  +2    -0    core/utilities/queuemanager/manager/batchtoolsfactory.cpp

https://invent.kde.org/kde/digikam/commit/30b6acb3ca97789d05ae21a0bf1fe44249d52418
Comment 47 Maik Qualmann 2019-08-02 16:24:24 UTC
*** Bug 410518 has been marked as a duplicate of this bug. ***
Comment 48 Maik Qualmann 2019-08-05 16:29:25 UTC
*** Bug 410518 has been marked as a duplicate of this bug. ***
Comment 49 Joseph Reagle 2019-08-05 16:37:50 UTC
Crash report still present in 6.3.0

Process:               digikam [29398]
Path:                  /opt/digikam/*/digikam.app/Contents/MacOS/digikam
Identifier:            digikam
Version:               6.3.0 (6.3.0-git)
Code Type:             X86-64 (Native)
Parent Process:        ??? [1]
Responsible:           digikam [29398]
User ID:               502

Date/Time:             2019-08-05 08:19:17.875 -0400
OS Version:            Mac OS X 10.14.6 (18G84)
Report Version:        12
Bridge OS Version:     3.6 (16P6568)
Anonymous UUID:        A3B78802-9A75-4BA9-6ADB-E84F5DFAEEF3


Time Awake Since Boot: 1000000 seconds

System Integrity Protection: enabled

Crashed Thread:        0  Dispatch queue: com.apple.main-thread

Exception Type:        EXC_BAD_ACCESS (SIGSEGV)
Exception Codes:       KERN_PROTECTION_FAILURE at 0x00007ffeea24a330
Exception Note:        EXC_CORPSE_NOTIFY

Termination Signal:    Segmentation fault: 11
Termination Reason:    Namespace SIGNAL, Code 0xb
Terminating Process:   exc handler [29398]

VM Regions Near 0x7ffeea24a330:
    STACK GUARD            00007ffee624b000-00007ffee9a4b000 [ 56.0M] ---/rwx SM=NUL  stack guard for thread 0
--> Stack                  00007ffee9a4b000-00007ffeea24b000 [ 8192K] rw-/rwx SM=SHM  thread 0
    Submap                 00007fff00000000-00007fff80000000 [  2.0G] r--/rwx SM=SHM  machine-wide VM submap

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0   ???                           	0x00007ffeea24a330 0 + 140732826690352
...
Comment 50 Maik Qualmann 2019-08-05 21:23:10 UTC
Git commit fd737c0dfd7939877dedebd9f8f673a3b432749b by Maik Qualmann.
Committed on 05/08/2019 at 21:21.
Pushed by mqualmann into branch 'master'.

after deep debugging this should fix the crash

M  +3    -0    core/app/main/digikamapp.cpp
M  +7    -0    core/utilities/queuemanager/dplugins/dpluginbqm.cpp
M  +0    -5    core/utilities/queuemanager/views/toolsettingsview.cpp

https://invent.kde.org/kde/digikam/commit/fd737c0dfd7939877dedebd9f8f673a3b432749b
Comment 51 Maik Qualmann 2019-08-16 13:03:23 UTC
Is the crash still reproducible under OSX?

https://files.kde.org/digikam/

Maik
Comment 52 Keith Yang 2019-08-16 14:00:41 UTC
Created attachment 122177 [details]
Crash report of quiting 6.3.0-git-20190811T185852-MacOS-x86-64 on macOS 10.14.6 Mojave

Yes, I downloaded 6.3.0-git-20190811T185852-MacOS-x86-64 version and it still crashed during quiting. I tried again and still crashed.
Comment 53 Keith Yang 2019-08-16 14:03:25 UTC
Created attachment 122179 [details]
Crash report of 2ed time quiting 6.3.0-git-20190811T185852-MacOS-x86-64 on macOS 10.14.6 Mojave

Second time crash report. Mostly memory address diff. But still some processing order diffs.
Comment 54 Maik Qualmann 2019-08-16 14:54:57 UTC
I'll add debug messages on exit to see when it crashes. Maybe we need to add a cleanup function to the DPlugins. For example, the BQM window that we quit via close will actually be deleted after exiting the digiKam main window. The DPlugins are then already deleted. Strange only that it is not to be reproduced under Linux or Windows.

Maik
Comment 55 Maik Qualmann 2019-08-16 18:16:10 UTC
Git commit 4de1ad3e5a04ce640714e63e55a74556e9c24bd9 by Maik Qualmann.
Committed on 16/08/2019 at 18:15.
Pushed by mqualmann into branch 'master'.

expand the DPlugin API with a cleanUp() function

M  +4    -0    core/dplugins/generic/import/dscanner/dscannerplugin.cpp
M  +1    -0    core/dplugins/generic/import/dscanner/dscannerplugin.h
M  +1    -1    core/dplugins/generic/tools/calendar/calendarplugin.cpp
M  +4    -0    core/dplugins/generic/tools/expoblending/expoblendingplugin.cpp
M  +1    -0    core/dplugins/generic/tools/expoblending/expoblendingplugin.h
M  +4    -0    core/dplugins/generic/tools/mediaserver/mediaserverplugin.cpp
M  +1    -0    core/dplugins/generic/tools/mediaserver/mediaserverplugin.h
M  +4    -0    core/dplugins/generic/tools/panorama/panoramaplugin.cpp
M  +1    -0    core/dplugins/generic/tools/panorama/panoramaplugin.h
M  +4    -0    core/dplugins/generic/webservices/box/boxplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/box/boxplugin.h
M  +4    -0    core/dplugins/generic/webservices/debianscreenshots/dsplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/debianscreenshots/dsplugin.h
M  +4    -0    core/dplugins/generic/webservices/dropbox/dbplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/dropbox/dbplugin.h
M  +4    -0    core/dplugins/generic/webservices/facebook/fbplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/facebook/fbplugin.h
M  +4    -0    core/dplugins/generic/webservices/filecopy/fcplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/filecopy/fcplugin.h
M  +4    -0    core/dplugins/generic/webservices/filetransfer/ftplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/filetransfer/ftplugin.h
M  +4    -0    core/dplugins/generic/webservices/flickr/flickrplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/flickr/flickrplugin.h
M  +4    -0    core/dplugins/generic/webservices/google/gsplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/google/gsplugin.h
M  +4    -0    core/dplugins/generic/webservices/imageshack/imageshackplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/imageshack/imageshackplugin.h
M  +4    -0    core/dplugins/generic/webservices/imgur/imgurplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/imgur/imgurplugin.h
M  +4    -0    core/dplugins/generic/webservices/ipfs/ipfsplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/ipfs/ipfsplugin.h
M  +4    -0    core/dplugins/generic/webservices/mediawiki/mediawikiplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/mediawiki/mediawikiplugin.h
M  +4    -0    core/dplugins/generic/webservices/onedrive/odplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/onedrive/odplugin.h
M  +4    -0    core/dplugins/generic/webservices/pinterest/pplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/pinterest/pplugin.h
M  +4    -0    core/dplugins/generic/webservices/piwigo/piwigoplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/piwigo/piwigoplugin.h
M  +4    -0    core/dplugins/generic/webservices/rajce/rajceplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/rajce/rajceplugin.h
M  +4    -0    core/dplugins/generic/webservices/smugmug/smugplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/smugmug/smugplugin.h
M  +4    -0    core/dplugins/generic/webservices/twitter/twitterplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/twitter/twitterplugin.h
M  +4    -0    core/dplugins/generic/webservices/unified/unifiedplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/unified/unifiedplugin.h
M  +4    -0    core/dplugins/generic/webservices/vkontakte/vkplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/vkontakte/vkplugin.h
M  +4    -0    core/dplugins/generic/webservices/yandexfotki/yfplugin.cpp
M  +1    -0    core/dplugins/generic/webservices/yandexfotki/yfplugin.h
M  +4    -0    core/libs/dplugins/core/dplugin.cpp
M  +5    -0    core/libs/dplugins/core/dplugin.h
M  +2    -4    core/libs/dplugins/setup/dpluginloader.cpp
M  +1    -2    core/libs/dplugins/setup/dpluginloader_p.cpp
M  +0    -1    core/libs/dplugins/setup/dpluginloader_p.h

https://invent.kde.org/kde/digikam/commit/4de1ad3e5a04ce640714e63e55a74556e9c24bd9
Comment 56 Maik Qualmann 2019-08-25 16:22:48 UTC
New OSX packages are available. Is the crash still to reproduce?

https://files.kde.org/digikam/

Maik
Comment 57 Keith Yang 2019-08-26 15:14:45 UTC
No crash in digiKam-6.3.0-git-20190824T122339-MacOS-x86-64.pkg in my two casual tests (open, wait, and close, wait, check no digiKam process remained, open, wait, and close). Thanks for the sweet fix!
Comment 58 caulier.gilles 2019-08-26 15:16:13 UTC
Thanks for the feedback

Gilles Caulier