diff options
Diffstat (limited to 'xorg-server/xkb/xkb.c')
-rw-r--r-- | xorg-server/xkb/xkb.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/xorg-server/xkb/xkb.c b/xorg-server/xkb/xkb.c index 9b643c8b9..ce4d7bd78 100644 --- a/xorg-server/xkb/xkb.c +++ b/xorg-server/xkb/xkb.c @@ -2777,9 +2777,8 @@ _XkbSetCompatMap(ClientPtr client, DeviceIntPtr dev, XkbSymInterpretPtr sym;
if ((unsigned)(req->firstSI+req->nSI)>compat->num_si) {
compat->num_si= req->firstSI+req->nSI;
- compat->sym_interpret= _XkbTypedRealloc(compat->sym_interpret,
- compat->num_si,
- XkbSymInterpretRec);
+ compat->sym_interpret= xrealloc(compat->sym_interpret,
+ compat->num_si * sizeof(XkbSymInterpretRec));
if (!compat->sym_interpret) {
compat->num_si= 0;
return BadAlloc;
@@ -6462,7 +6461,7 @@ _XkbSetDeviceInfoCheck(ClientPtr client, DeviceIntPtr dev, nBtns= dev->button->numButtons;
acts= dev->button->xkb_acts;
if (acts==NULL) {
- acts= _XkbTypedCalloc(nBtns,XkbAction);
+ acts= xcalloc(nBtns, sizeof(XkbAction));
if (!acts)
return BadAlloc;
dev->button->xkb_acts= acts;
|