BackupManager: Manually delete the backup job
The backup job is run in a separate thread, and when the job completes the thread is told to quit and then delete itself. Therefore, based on the timing two posibilities can occur, and the job finished signal is queued in the main event loop. 1. The backup thread is deleted, and therefore the backup job never gets deleted (since its eventloop has been deleted) -> Memory Leak 2. A crash since the job has been deleted and then the slotBackupDone function tries to access its members. This was the reason the backup test was occasionally failing. Edit: No. This doesn't fix the crash. It in fact makes it crash reliably when running the backup test. For now I'm not deleting the job. This introduced a small memory leak, but that is better than a crash. We do not want the backup process to ever crash because it is used in the migration process. @Simeon: Could you please take a look at the crash? Run the backuptest tagsAndRatings to reliably reproduce it. You'll have to uncomment the // delete job. CCMAIL: nepomuk@kde.org
parent
fb71592b
Please register or sign in to comment