Skip to content

Commit da28cb8

Browse files
18202781743deepin-bot[bot]
authored andcommitted
fix: initialize dock color theme with default value
1. Changed m_dockColorTheme initialization from uninitialized to -1 2. Prevents potential undefined behavior when accessing uninitialized variable 3. Ensures consistent behavior when dock color theme is not set fix: 初始化 dock 颜色主题默认值 1. 将 m_dockColorTheme 从未初始化状态改为初始化为 -1 2. 防止访问未初始化变量时出现未定义行为 3. 确保当 dock 颜色主题未设置时行为一致 pms: BUG-314263
1 parent 680ed58 commit da28cb8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

panels/dock/pluginmanagerextension_p.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,8 +108,8 @@ private Q_SLOTS:
108108
private:
109109
QList<PluginSurface*> m_pluginSurfaces;
110110

111-
uint32_t m_dockPosition;
112-
uint32_t m_dockColorTheme;
111+
uint32_t m_dockPosition = 0;
112+
uint32_t m_dockColorTheme = 0;
113113
QSize m_dockSize;
114114
int m_popupMinHeight = 0;
115115
};

0 commit comments

Comments
 (0)