mirror of
https://github.com/X11Libre/xserver.git
synced 2026-03-24 08:04:30 +00:00
Bug #12531: RRModesForScreen can fail to allocate.
This commit is contained in:
committed by
Adam Jackson
parent
fac7e7e4e1
commit
a46c30c3be
@@ -165,6 +165,8 @@ RRModesForScreen (ScreenPtr pScreen, int *num_ret)
|
||||
int num_screen_modes = 0;
|
||||
|
||||
screen_modes = xalloc ((num_modes ? num_modes : 1) * sizeof (RRModePtr));
|
||||
if (!screen_modes)
|
||||
return NULL;
|
||||
|
||||
/*
|
||||
* Add modes from all outputs
|
||||
|
||||
Reference in New Issue
Block a user