tray: Don't call g_object_unref(NULL)
g_object_unref() only accepts valid object instances. Signed-off-by: Simon McVittie <smcv@collabora.com>
This commit is contained in:
1 parent
0bc370dfba
commit
bba066c44c
1 file changed
+3
-1
@@ -671,7 +671,9 @@ void SDL_DestroyTray(SDL_Tray *tray)
|
||||
SDL_RemovePath(tray->icon_path);
|
||||
}
|
||||
|
||||
g_object_unref(tray->indicator);
|
||||
if (tray->indicator) {
|
||||
g_object_unref(tray->indicator);
|
||||
}
|
||||
|
||||
SDL_free(tray);
|
||||
|
||||
|
||||
Reference in new issue
Block a user