diff options
author | Mikhail Gusarov <dottedmag@dottedmag.net> | 2010-05-06 01:44:06 +0700 |
---|---|---|
committer | Mikhail Gusarov <dottedmag@dottedmag.net> | 2010-05-13 00:22:37 +0700 |
commit | 3f3ff971ecff9936cebafc813af9193b97bba89c (patch) | |
tree | fdbbad794a42488b7ffe41eed7aba4e498335f55 /dix/ptrveloc.c | |
parent | 96c7ab27c383ec767f62a7a11e5fd76f86363fbc (diff) |
Replace X-allocation functions with their C89 counterparts
The only remaining X-functions used in server are XNF*, the rest is converted to
plain alloc/calloc/realloc/free/strdup.
X* functions are still exported from server and x* macros are still defined in
header file, so both ABI and API are not affected by this change.
Signed-off-by: Mikhail Gusarov <dottedmag@dottedmag.net>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to 'dix/ptrveloc.c')
-rw-r--r-- | dix/ptrveloc.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/dix/ptrveloc.c b/dix/ptrveloc.c index 100d6f8be..cedc829d0 100644 --- a/dix/ptrveloc.c +++ b/dix/ptrveloc.c @@ -111,7 +111,7 @@ InitVelocityData(DeviceVelocityPtr vel) */ void FreeVelocityData(DeviceVelocityPtr vel){ - xfree(vel->tracker); + free(vel->tracker); SetAccelerationProfile(vel, PROFILE_UNINITIALIZE); } @@ -127,7 +127,7 @@ AccelerationDefaultCleanup(DeviceIntPtr dev) && dev->valuator->accelScheme.accelData != NULL){ dev->valuator->accelScheme.AccelSchemeProc = NULL; FreeVelocityData(dev->valuator->accelScheme.accelData); - xfree(dev->valuator->accelScheme.accelData); + free(dev->valuator->accelScheme.accelData); dev->valuator->accelScheme.accelData = NULL; DeletePredictableAccelerationProperties(dev); } @@ -372,8 +372,8 @@ InitTrackers(DeviceVelocityPtr vel, int ntracker) ErrorF("(dix ptracc) invalid number of trackers\n"); return; } - xfree(vel->tracker); - vel->tracker = (MotionTrackerPtr)xalloc(ntracker * sizeof(MotionTracker)); + free(vel->tracker); + vel->tracker = (MotionTrackerPtr)malloc(ntracker * sizeof(MotionTracker)); memset(vel->tracker, 0, ntracker * sizeof(MotionTracker)); vel->num_tracker = ntracker; } @@ -954,7 +954,7 @@ SetAccelerationProfile( if(vel->profile_private != NULL){ /* Here one could free old profile-private data */ - xfree(vel->profile_private); + free(vel->profile_private); vel->profile_private = NULL; } /* Here one could init profile-private data */ |