xserver/hw/xwin
Enrico Weigelt, metux IT consult 6a8ee31e1b dix: move props into WindowRec and fix potential NULL deref
The pointer to the window properties is currently inside the WindowOptional
structure, which may or may not exist at any given time. Thus, before accessing
those fields, at least need to check whether it exists, potentially need to
create it first.

Since a pointer is small (in relation to WindowRec) and windows having properties
is a pretty common, we can make our life much simpler here by moving the pointer
directly into WindowRec, so we don't need extra WindowOptionalRec allocation.

This also fixes an analyzer warning on potential NULL dereference issue:

| ../dix/property.c: In function ‘dixChangeWindowProperty’:
|../dix/property.c:343:37: warning: dereference of NULL ‘*pWin.optional’ [CWE-476] [-Wanalyzer-null-dereference]
|  343 |         pProp->next = pWin->optional->userProps;
|      |                       ~~~~~~~~~~~~~~^~~~~~~~~~~

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-06-12 16:34:03 +02:00
..
dri xwin: drop swapping request length fields 2025-02-06 22:28:51 +00:00
glx build: Switch to meson 0.56 2024-01-08 10:38:05 +00:00
man XWin.man: fix typos in font change escapes 2025-05-31 15:06:23 -07:00
winclipboard man pages: use .BR to mark up man page references 2025-03-29 13:36:54 -07:00
.gitignore
InitInput.c mi: unexport mieqInit() 2025-02-06 16:45:20 +02:00
InitOutput.c xwin: drop duplicate OsVendorVErrorF() 2025-02-06 23:35:27 +00:00
X.ico
XWin.exe.manifest
XWin.rc
ddraw.h
meson.build meson: Add dependencies for hw/xwin/ resource compilation 2021-11-04 13:03:25 +00:00
propertystore.h
system.XWinrc
win.h xwin: drop duplicate OsVendorVErrorF() 2025-02-06 23:35:27 +00:00
winSetAppUserModelID.c
winallpriv.c Move sizeof to second argument in calloc calls 2024-07-19 23:45:21 +00:00
winauth.c os: unexport authorization management functions 2024-04-15 14:55:22 -07:00
winauth.h
winblock.c
winclipboardinit.c
winclipboardwrappers.c include: move private defs to dixstruct_priv.h 2024-04-30 00:47:38 +00:00
wincmap.c dix: unexport CreateColormap() 2024-09-01 22:06:49 +00:00
winconfig.c
winconfig.h
wincreatewnd.c dix: unexport fields from opaque.h not used by modules/drivers 2024-06-23 21:19:27 +00:00
wincursor.c mi: unexport miPointerWarpCursor() 2025-02-06 14:38:05 +00:00
windialogs.c xwin: consolidate debugging symbols 2024-03-19 02:05:35 +00:00
windisplay.c dix: unexport fields from opaque.h not used by modules/drivers 2024-06-23 21:19:27 +00:00
windisplay.h
winengine.c
winerror.c xwin: drop duplicate OsVendorVErrorF() 2025-02-06 23:35:27 +00:00
winglobals.c
winglobals.h
winkeybd.c mi: unexport mieqProcessInputEvents() 2025-02-06 16:45:20 +02:00
winkeybd.h
winkeyhook.c
winkeynames.h
winlayouts.h
winmessages.h
winmisc.c
winmonitors.c
winmonitors.h
winmouse.c xwin: consolidate debugging symbols 2024-03-19 02:05:35 +00:00
winms.h
winmsg.c xwin: consolidate debugging symbols 2024-03-19 02:05:35 +00:00
winmsg.h
winmsgwindow.c xwin: consolidate debugging symbols 2024-03-19 02:05:35 +00:00
winmultiwindowclass.c dix: move props into WindowRec and fix potential NULL deref 2025-06-12 16:34:03 +02:00
winmultiwindowclass.h
winmultiwindowicons.c xwin: winsock.h needs to be included earlier 2024-03-03 23:02:54 +00:00
winmultiwindowicons.h
winmultiwindowshape.c xwin: consolidate debugging symbols 2024-03-19 02:05:35 +00:00
winmultiwindowwindow.c include: drop obsolete dixevents.h 2025-06-12 16:17:35 +02:00
winmultiwindowwm.c Move sizeof to second argument in calloc calls 2024-07-19 23:45:21 +00:00
winmultiwindowwndproc.c include: drop obsolete dixevents.h 2025-06-12 16:17:35 +02:00
winos.c
winprefs.c xwin: fix unused variables 2024-03-03 23:02:54 +00:00
winprefs.h
winprefslex.l
winprefsyacc.y
winprocarg.c xwin: drop duplicate OsVendorVErrorF() 2025-02-06 23:35:27 +00:00
winrandr.c randr: unexport and document RROutputSetSubpixelOrder() 2025-06-12 16:28:53 +02:00
winresource.h
winscrinit.c xwin: consolidate debugging symbols 2024-03-19 02:05:35 +00:00
winshadddnl.c dix: move colormap flags into colormap_priv.h and rename them 2024-09-01 22:06:50 +00:00
winshadgdi.c dix: move colormap flags into colormap_priv.h and rename them 2024-09-01 22:06:50 +00:00
wintaskbar.c
wintrayicon.c dix: unexport fields from opaque.h not used by modules/drivers 2024-06-23 21:19:27 +00:00
winvalargs.c
winwakeup.c
winwindow.c xwin: consolidate debugging symbols 2024-03-19 02:05:35 +00:00
winwindow.h xwin: consolidate debugging symbols 2024-03-19 02:05:35 +00:00
winwndproc.c mi: unexport miPointerSetScreen() 2025-02-06 14:38:05 +00:00