signalapp / Signal-iOS

A private messenger for iOS.
https://signal.org
GNU Affero General Public License v3.0
10.59k stars 2.95k forks source link

SQLite error 11 database disk image is malformed after iOS crash while Signal was open in background of low storage message #5813

Open MartinEesmaa opened 1 month ago

MartinEesmaa commented 1 month ago

Bug description

The bug has occurred when I'm trying to take multiple screenshots on my iPad with low storage while Signal is open in background with low storage warning message.

Steps to reproduce

Actual result: Signal couldn't load database after crash with low storage and still open in background of Signal app.

Expected result: Before system crashes, Signal app may exit not forcing before crash, should recover database and back to there or make backup database of another file before crashes again. After iOS crash, Signal should open database correctly with normal operation.

Quick log:

2024/05/20 08:18:08:903  ❤️ [NotificationService.swift:114 didReceive(_:withContentHandler:)]: Couldn't load database: SQLite error 11: Optional("database disk image is malformed") (extended result code: 11)
2024/05/20 08:18:19:403  💛 [NSEEnvironment.swift:120 setUp(logger:)]: [NSE] pid: 856, memoryUsage: 3343160 {{xxxx-xx-xx-xxxB82}}
2024/05/20 08:18:19:405  ❤️ [OWSFileSystem.m:78 +[OWSFileSystem protectFileOrFolderAtPath:fileProtectionType:]]: Could not protect file or folder: NSCocoaErrorDomain/513, NSPOSIXErrorDomain/1

Screenshots (this was on May 3rd 2024 screenshotted, still I have an issue ongoing after I published an issue)

signalnotloadafterioscrash

Device info

Device: iPad 9th Generation

iOS version: 17.5.1

Signal version: 7.11

Link to debug log

b8437e19c349b54243bce4b44cf6c0b86a156a5886862506ccf20a7a67a55a39.zip (permanent link from GitHub)

If you would like to request more debug logs from past dates, let me know. Thanks! :)

Sincerely, Martin Eesmaa