Change fade callback function parameter

Change `win *` to `win **`, because a window could be freed by the
callback, so we can set `*w` to NULL to communicate that.

Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
This commit is contained in:
Yuxuan Shui
2018-09-29 23:30:19 +01:00
parent 417744df14
commit ab12467c3f
3 changed files with 52 additions and 65 deletions

View File

@ -1162,7 +1162,7 @@ struct win {
/// Override value of window fade state. Set by D-Bus method calls.
switch_t fade_force;
/// Callback to be called after fading completed.
void (*fade_callback) (session_t *ps, win *w);
void (*fade_callback) (session_t *ps, win **w);
// Frame-opacity-related members
/// Current window frame opacity. Affected by window opacity.