* updated maddy (0.7.1 -> 0.8.1), untested
[t2sde.git] / package / xorg / xorg-server / hotfix-lookupmode.patch
blobc809e3d62c8f4b253628223fcd1fcf558d97433a
1 # --- T2-COPYRIGHT-NOTE-BEGIN ---
2 # T2 SDE: package/*/xorg-server/hotfix-lookupmode.patch
3 # Copyright (C) 2024 The T2 SDE Project
4 #
5 # This Copyright note is generated by scripts/Create-CopyPatch,
6 # more information can be found in the files COPYING and README.
7 #
8 # This patch file is dual-licensed. It is available under the license the
9 # patched project is licensed under, as long as it is an OpenSource license
10 # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
11 # of the GNU General Public License version 2 as used by the T2 SDE.
12 # --- T2-COPYRIGHT-NOTE-END ---
14 diff --git a/hw/xfree86/common/xf86Mode.c b/hw/xfree86/common/xf86Mode.c
15 index 136cd15d0..a28973ead 100644
16 --- a/hw/xfree86/common/xf86Mode.c
17 +++ b/hw/xfree86/common/xf86Mode.c
18 @@ -509,6 +509,8 @@ xf86LookupMode(ScrnInfoPtr scrp, DisplayModePtr modep,
19 /* scan through the modes in the sort order above */
20 if ((p->type & type) != type)
21 continue;
22 + if (p->name == NULL)
23 + continue;
25 if (strcmp(p->name, modep->name) == 0) {