summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Xi/xiquerydevice.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/Xi/xiquerydevice.c b/Xi/xiquerydevice.c
index 8b5421130..8b6990491 100644
--- a/Xi/xiquerydevice.c
+++ b/Xi/xiquerydevice.c
@@ -107,8 +107,10 @@ ProcXIQueryDevice(ClientPtr client)
}
info = calloc(1, len);
- if (!info)
+ if (!info) {
+ free(skip);
return BadAlloc;
+ }
memset(&rep, 0, sizeof(xXIQueryDeviceReply));
rep.repType = X_Reply;