Bug #16674: Make sure RANDR reports refresh as 0 if pixel clock is 0.
(cherry picked from commit 9111944b29
)
This commit is contained in:
parent
5b546f1c49
commit
2b3faf2a75
|
@ -54,6 +54,8 @@ xf86RandRModeRefresh (DisplayModePtr mode)
|
|||
{
|
||||
if (mode->VRefresh)
|
||||
return (int) (mode->VRefresh + 0.5);
|
||||
else if (mode->Clock == 0)
|
||||
return 0;
|
||||
else
|
||||
return (int) (mode->Clock * 1000.0 / mode->HTotal / mode->VTotal + 0.5);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user