mirror of
https://git.outfoxxed.me/quickshell/quickshell.git
synced 2026-02-23 03:33:57 +11:00
all: fix gcc warnings and lints
This commit is contained in:
parent
9bb2c043ae
commit
c5c438f1cd
11 changed files with 42 additions and 16 deletions
|
|
@ -77,7 +77,11 @@ void CrashHandler::setRelaunchInfo(const RelaunchInfo& info) {
|
|||
}
|
||||
|
||||
QFile file;
|
||||
file.open(this->d->infoFd, QFile::ReadWrite);
|
||||
|
||||
if (!file.open(this->d->infoFd, QFile::ReadWrite)) {
|
||||
qCCritical(logCrashHandler
|
||||
) << "Failed to open instance info memfd, crash recovery will not work.";
|
||||
}
|
||||
|
||||
QDataStream ds(&file);
|
||||
ds << info;
|
||||
|
|
|
|||
|
|
@ -161,7 +161,10 @@ void qsCheckCrash(int argc, char** argv) {
|
|||
auto infoFd = qEnvironmentVariable("__QUICKSHELL_CRASH_INFO_FD").toInt();
|
||||
|
||||
QFile file;
|
||||
file.open(infoFd, QFile::ReadOnly, QFile::AutoCloseHandle);
|
||||
if (!file.open(infoFd, QFile::ReadOnly, QFile::AutoCloseHandle)) {
|
||||
qFatal() << "Failed to open instance info fd.";
|
||||
}
|
||||
|
||||
file.seek(0);
|
||||
|
||||
auto ds = QDataStream(&file);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue