Skip to content

Commit 45c5e12

Browse files
Ryexs0me1newithhand7s
authored andcommitted
fix: nullptr access
style can't always be created Signed-off-by: Rachel Powers <508861+Ryex@users.noreply.github.com> (cherry picked from commit 83ebb59)
1 parent c16e1e2 commit 45c5e12

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

launcher/ui/themes/SystemTheme.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ SystemTheme::SystemTheme(const QString& styleName, const QPalette& defaultPalett
5454
m_colorPalette = defaultPalette;
5555
} else {
5656
auto style = QStyleFactory::create(styleName);
57-
m_colorPalette = style->standardPalette();
57+
m_colorPalette = style != nullptr ? style->standardPalette() : defaultPalette;
5858
delete style;
5959
}
6060
}

0 commit comments

Comments
 (0)