src/video/x11/SDL_x11modes.c
changeset 10437 d62c4978fffa
parent 10172 b4316ed0c72c
child 10499 363c1c7e7a41
     1.1 --- a/src/video/x11/SDL_x11modes.c	Wed Sep 30 04:16:09 2015 +0100
     1.2 +++ b/src/video/x11/SDL_x11modes.c	Sat Oct 01 14:16:04 2016 -0700
     1.3 @@ -264,8 +264,8 @@
     1.4  static int
     1.5  CalculateXRandRRefreshRate(const XRRModeInfo *info)
     1.6  {
     1.7 -    return (info->hTotal
     1.8 -            && info->vTotal) ? (info->dotClock / (info->hTotal * info->vTotal)) : 0;
     1.9 +    return (info->hTotal && info->vTotal) ?
    1.10 +        round(((double)info->dotClock / (double)(info->hTotal * info->vTotal))) : 0;
    1.11  }
    1.12  
    1.13  static SDL_bool