mirror of
https://github.com/X11Libre/xserver.git
synced 2026-03-24 08:04:30 +00:00
dix: protect doPolyText() from potential NULL dereference
There's a (theoretical) chance that origGC might be NULL, so better be cautious and check for this - doesn't cost us much, probably just another JZ instruction. Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
This commit is contained in:
@@ -1317,7 +1317,7 @@ doPolyText(ClientPtr client, PTclosurePtr c)
|
||||
|
||||
if (client_state == START_SLEEP) {
|
||||
/* Step 4 */
|
||||
if (pFont != origGC->font) {
|
||||
if (origGC && (pFont != origGC->font)) {
|
||||
ChangeGCVal val;
|
||||
|
||||
val.ptr = pFont;
|
||||
|
||||
Reference in New Issue
Block a user