mirror of
https://gitlab.freedesktop.org/xorg/xserver.git
synced 2026-01-08 11:50:15 +01:00
Set property data to 0 when translation failed to avoid having the data accidentally reference some other existing resource.
This commit is contained in:
parent
7f01e9694c
commit
72ceaa9acf
1 changed files with 8 additions and 8 deletions
|
|
@ -1233,7 +1233,7 @@ dmxTranslateWindowProperty (WindowPtr pWindow,
|
|||
if (name)
|
||||
*dst = XInternAtom (dmxScreen->beDisplay, name, FALSE);
|
||||
else
|
||||
*dst = *src;
|
||||
*dst = 0;
|
||||
} break;
|
||||
case 'p':
|
||||
case 'P': {
|
||||
|
|
@ -1263,7 +1263,7 @@ dmxTranslateWindowProperty (WindowPtr pWindow,
|
|||
DixReadAccess) == Success)
|
||||
*dst = (DMX_GET_PIXMAP_PRIV (pPixmap))->pixmap;
|
||||
else
|
||||
*dst = *src;
|
||||
*dst = 0;
|
||||
} break;
|
||||
case 'm':
|
||||
case 'M': {
|
||||
|
|
@ -1293,7 +1293,7 @@ dmxTranslateWindowProperty (WindowPtr pWindow,
|
|||
DixReadAccess) == Success)
|
||||
*dst = (DMX_GET_COLORMAP_PRIV (pColormap))->cmap;
|
||||
else
|
||||
*dst = *src;
|
||||
*dst = 0;
|
||||
} break;
|
||||
case 'c':
|
||||
case 'C': {
|
||||
|
|
@ -1308,7 +1308,7 @@ dmxTranslateWindowProperty (WindowPtr pWindow,
|
|||
DixReadAccess) == Success)
|
||||
*dst = (DMX_GET_CURSOR_PRIV (pCursor, pScreen))->cursor;
|
||||
else
|
||||
*dst = *src;
|
||||
*dst = 0;
|
||||
} break;
|
||||
case 'd':
|
||||
case 'D': {
|
||||
|
|
@ -1351,7 +1351,7 @@ dmxTranslateWindowProperty (WindowPtr pWindow,
|
|||
}
|
||||
}
|
||||
else
|
||||
*dst = *src;
|
||||
*dst = 0;
|
||||
} break;
|
||||
case 'f':
|
||||
case 'F': {
|
||||
|
|
@ -1371,7 +1371,7 @@ dmxTranslateWindowProperty (WindowPtr pWindow,
|
|||
*dst = pFontPriv->font[pScreen->myNum]->fid;
|
||||
}
|
||||
else
|
||||
*dst = *src;
|
||||
*dst = 0;
|
||||
} break;
|
||||
case 'v':
|
||||
case 'V': {
|
||||
|
|
@ -1383,7 +1383,7 @@ dmxTranslateWindowProperty (WindowPtr pWindow,
|
|||
if (visual)
|
||||
*dst = XVisualIDFromVisual (visual);
|
||||
else
|
||||
*dst = *src;
|
||||
*dst = 0;
|
||||
} break;
|
||||
case 'w':
|
||||
case 'W': {
|
||||
|
|
@ -1413,7 +1413,7 @@ dmxTranslateWindowProperty (WindowPtr pWindow,
|
|||
DixReadAccess) == Success)
|
||||
*dst = (DMX_GET_WINDOW_PRIV (pWin))->window;
|
||||
else
|
||||
*dst = *src;
|
||||
*dst = 0;
|
||||
} break;
|
||||
default:
|
||||
*((CARD32 *) output) = *((CARD32 *) data);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue