Skip to content

Commit

Permalink
Check parent variable nullness in folderstatusmodel
Browse files Browse the repository at this point in the history
Signed-off-by: Claudio Cambra <[email protected]>
  • Loading branch information
claucambra committed Mar 3, 2024
1 parent d8d104f commit dbfcd10
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/gui/folderstatusmodel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -956,8 +956,7 @@ void FolderStatusModel::slotApplySelectiveSync()

void FolderStatusModel::slotSetProgress(const ProgressInfo &progress)
{
const auto parent = qobject_cast<QWidget *>(QObject::parent());
if (!parent->isVisible()) {
if (const auto parent = qobject_cast<QWidget *>(QObject::parent()); !parent || !parent->isVisible()) {
return; // for https://github.com/owncloud/client/issues/2648#issuecomment-71377909
}

Expand Down

0 comments on commit dbfcd10

Please sign in to comment.