Workaround compiling with -ffast-math

And add a compiler warning.

Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
This commit is contained in:
Yuxuan Shui
2018-11-02 13:57:19 +00:00
parent 45e9530bcb
commit be09a9a835
3 changed files with 13 additions and 2 deletions

View File

@ -324,7 +324,7 @@ void win_calc_opacity(session_t *ps, win *w) {
// Try obeying opacity property and window type opacity firstly
if (w->has_opacity_prop)
opacity = w->opacity_prop;
else if (!isnan(ps->o.wintype_opacity[w->window_type]))
else if (!safe_isnan(ps->o.wintype_opacity[w->window_type]))
opacity = ps->o.wintype_opacity[w->window_type] * OPAQUE;
else {
// Respect active_opacity only when the window is physically focused