[PATCH xf86-input-vmmouse 1/2] Deprecated code cleanup.
Thomas Hellstrom
thellstrom at shipmail.org
Mon Oct 18 23:26:30 PDT 2010
On 10/19/2010 01:14 AM, Peter Hutterer wrote:
> On Mon, Oct 18, 2010 at 12:11:24PM -0400, Trevor Woerner wrote:
>
>> From: Trevor Woerner<twoerner at gmail.com>
>>
>> Signed-off-by: Trevor Woerner<twoerner at gmail.com>
>>
> Reviewed-by: Peter Hutterer<peter.hutterer at who-t.net>
>
>
Nak in its current form.
We're maintaining backwards compatibility of this driver and
xf86-video-vmware back to Xserver 1.0, which means for this code we need
a couple of extra headers for it to compile,
(please see how this was done in one of the latest commits of
xf86-video-vmware).
If you want to respin the patch, please let me know. Otherwise I could
do that.
Thanks,
Thomas
>> ---
>> src/vmmouse.c | 18 +++++++++---------
>> 1 files changed, 9 insertions(+), 9 deletions(-)
>>
>> diff --git a/src/vmmouse.c b/src/vmmouse.c
>> index f5ad234..1154762 100644
>> --- a/src/vmmouse.c
>> +++ b/src/vmmouse.c
>> @@ -249,7 +249,7 @@ VMMousePreInit(InputDriverPtr drv, IDevPtr dev, int flags)
>> }
>> #endif
>>
>> - mPriv = xcalloc (1, sizeof (VMMousePrivRec));
>> + mPriv = calloc (1, sizeof (VMMousePrivRec));
>>
>>
>> if (!mPriv) {
>> @@ -270,7 +270,7 @@ VMMousePreInit(InputDriverPtr drv, IDevPtr dev, int flags)
>> xf86Msg(X_ERROR, "VMWARE(0): vmmouse enable failed\n");
>> mPriv->vmmouseAvailable = FALSE;
>> passthruMouse = (InputDriverRec *)LoaderSymbol("MOUSE");
>> - xfree(mPriv);
>> + free(mPriv);
>> if(passthruMouse != NULL){
>> return (passthruMouse->PreInit)(drv, dev, flags);
>> } else {
>> @@ -291,7 +291,7 @@ VMMousePreInit(InputDriverPtr drv, IDevPtr dev, int flags)
>> }
>>
>> if (!(pInfo = xf86AllocateInput(drv, 0))) {
>> - xfree(mPriv);
>> + free(mPriv);
>> return NULL;
>> }
>>
>> @@ -316,8 +316,8 @@ VMMousePreInit(InputDriverPtr drv, IDevPtr dev, int flags)
>> pInfo->conf_idev = dev;
>>
>> /* Allocate the MouseDevRec and initialise it. */
>> - if (!(pMse = xcalloc(sizeof(MouseDevRec), 1))) {
>> - xfree(mPriv);
>> + if (!(pMse = calloc(sizeof(MouseDevRec), 1))) {
>> + free(mPriv);
>> return pInfo;
>> }
>>
>> @@ -340,8 +340,8 @@ VMMousePreInit(InputDriverPtr drv, IDevPtr dev, int flags)
>> else {
>> xf86Msg(X_ERROR, "%s: cannot open input device\n", pInfo->name);
>> if (pMse->mousePriv)
>> - xfree(pMse->mousePriv);
>> - xfree(pMse);
>> + free(pMse->mousePriv);
>> + free(pMse);
>> pInfo->private = NULL;
>> return pInfo;
>> }
>> @@ -645,7 +645,7 @@ MouseCommonOptions(InputInfoPtr pInfo)
>> }
>> if (msg) {
>> xf86Msg(X_CONFIG, "%s: ZAxisMapping: %s\n", pInfo->name, msg);
>> - xfree(msg);
>> + free(msg);
>> } else {
>> xf86Msg(X_WARNING, "%s: Invalid ZAxisMapping value: \"%s\"\n",
>> pInfo->name, s);
>> @@ -1201,7 +1201,7 @@ VMMousePlug(pointer module,
>> if (!LoadSubModule(module, name, NULL, NULL, NULL, NULL, errmaj, errmin)) {
>> LoaderErrorMsg(NULL, name, *errmaj, *errmin);
>> }
>> - xfree(name);
>> + free(name);
>> }
>> #endif
>>
>> --
>> 1.7.3.1.104.gc752e
>>
More information about the xorg-devel
mailing list