Fix more xcalloc stupidity.
Did I mention the hate? Pretty sure I mentioned the hate.
This commit is contained in:
parent
4fe80aa14a
commit
7aa535708f
|
@ -104,7 +104,7 @@ typedef struct _myPrivate {
|
||||||
pointer dmxBackendCreatePrivate(DeviceIntPtr pDevice)
|
pointer dmxBackendCreatePrivate(DeviceIntPtr pDevice)
|
||||||
{
|
{
|
||||||
GETDMXLOCALFROMPDEVICE;
|
GETDMXLOCALFROMPDEVICE;
|
||||||
myPrivate *priv = xcalloc(1, sizeof(*priv));
|
myPrivate *priv = calloc(1, sizeof(*priv));
|
||||||
priv->dmxLocal = dmxLocal;
|
priv->dmxLocal = dmxLocal;
|
||||||
return priv;
|
return priv;
|
||||||
}
|
}
|
||||||
|
@ -114,7 +114,7 @@ pointer dmxBackendCreatePrivate(DeviceIntPtr pDevice)
|
||||||
* #dmxBackendCreatePrivate. */
|
* #dmxBackendCreatePrivate. */
|
||||||
void dmxBackendDestroyPrivate(pointer private)
|
void dmxBackendDestroyPrivate(pointer private)
|
||||||
{
|
{
|
||||||
if (private) xfree(private);
|
if (private) free(private);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void *dmxBackendTestScreen(DMXScreenInfo *dmxScreen, void *closure)
|
static void *dmxBackendTestScreen(DMXScreenInfo *dmxScreen, void *closure)
|
||||||
|
|
|
@ -140,7 +140,7 @@ static int unscaley(myPrivate *priv, int y)
|
||||||
pointer dmxConsoleCreatePrivate(DeviceIntPtr pDevice)
|
pointer dmxConsoleCreatePrivate(DeviceIntPtr pDevice)
|
||||||
{
|
{
|
||||||
GETDMXLOCALFROMPDEVICE;
|
GETDMXLOCALFROMPDEVICE;
|
||||||
myPrivate *priv = xcalloc(1, sizeof(*priv));
|
myPrivate *priv = calloc(1, sizeof(*priv));
|
||||||
priv->dmxLocal = dmxLocal;
|
priv->dmxLocal = dmxLocal;
|
||||||
return priv;
|
return priv;
|
||||||
}
|
}
|
||||||
|
@ -148,7 +148,7 @@ pointer dmxConsoleCreatePrivate(DeviceIntPtr pDevice)
|
||||||
/** If \a private is non-NULL, free its associated memory. */
|
/** If \a private is non-NULL, free its associated memory. */
|
||||||
void dmxConsoleDestroyPrivate(pointer private)
|
void dmxConsoleDestroyPrivate(pointer private)
|
||||||
{
|
{
|
||||||
if (private) xfree(private);
|
if (private) free(private);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void dmxConsoleDrawFineCursor(myPrivate *priv, XRectangle *rect)
|
static void dmxConsoleDrawFineCursor(myPrivate *priv, XRectangle *rect)
|
||||||
|
|
|
@ -292,7 +292,7 @@ void msLinuxVTPostSwitch(pointer p)
|
||||||
/** Create a private structure for use within this file. */
|
/** Create a private structure for use within this file. */
|
||||||
pointer msLinuxCreatePrivate(DeviceIntPtr pMouse)
|
pointer msLinuxCreatePrivate(DeviceIntPtr pMouse)
|
||||||
{
|
{
|
||||||
myPrivate *priv = xcalloc(1, sizeof(*priv));
|
myPrivate *priv = calloc(1, sizeof(*priv));
|
||||||
priv->fd = -1;
|
priv->fd = -1;
|
||||||
priv->pMouse = pMouse;
|
priv->pMouse = pMouse;
|
||||||
return priv;
|
return priv;
|
||||||
|
@ -301,7 +301,7 @@ pointer msLinuxCreatePrivate(DeviceIntPtr pMouse)
|
||||||
/** Destroy a private structure. */
|
/** Destroy a private structure. */
|
||||||
void msLinuxDestroyPrivate(pointer priv)
|
void msLinuxDestroyPrivate(pointer priv)
|
||||||
{
|
{
|
||||||
if (priv) xfree(priv);
|
if (priv) free(priv);
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Fill the \a info structure with information needed to initialize \a
|
/** Fill the \a info structure with information needed to initialize \a
|
||||||
|
|
|
@ -260,7 +260,7 @@ void ps2LinuxVTPostSwitch(pointer p)
|
||||||
/** Create a private structure for use within this file. */
|
/** Create a private structure for use within this file. */
|
||||||
pointer ps2LinuxCreatePrivate(DeviceIntPtr pMouse)
|
pointer ps2LinuxCreatePrivate(DeviceIntPtr pMouse)
|
||||||
{
|
{
|
||||||
myPrivate *priv = xcalloc(1, sizeof(*priv));
|
myPrivate *priv = calloc(1, sizeof(*priv));
|
||||||
priv->fd = -1;
|
priv->fd = -1;
|
||||||
priv->pMouse = pMouse;
|
priv->pMouse = pMouse;
|
||||||
return priv;
|
return priv;
|
||||||
|
@ -269,7 +269,7 @@ pointer ps2LinuxCreatePrivate(DeviceIntPtr pMouse)
|
||||||
/** Destroy a private structure. */
|
/** Destroy a private structure. */
|
||||||
void ps2LinuxDestroyPrivate(pointer priv)
|
void ps2LinuxDestroyPrivate(pointer priv)
|
||||||
{
|
{
|
||||||
if (priv) xfree(priv);
|
if (priv) free(priv);
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Fill the \a info structure with information needed to initialize \a
|
/** Fill the \a info structure with information needed to initialize \a
|
||||||
|
|
|
@ -368,7 +368,7 @@ void usbOff(DevicePtr pDev)
|
||||||
/** Create a private structure for use within this file. */
|
/** Create a private structure for use within this file. */
|
||||||
pointer usbCreatePrivate(DeviceIntPtr pDevice)
|
pointer usbCreatePrivate(DeviceIntPtr pDevice)
|
||||||
{
|
{
|
||||||
myPrivate *priv = xcalloc(1, sizeof(*priv));
|
myPrivate *priv = calloc(1, sizeof(*priv));
|
||||||
priv->fd = -1;
|
priv->fd = -1;
|
||||||
priv->pDevice = pDevice;
|
priv->pDevice = pDevice;
|
||||||
return priv;
|
return priv;
|
||||||
|
@ -377,5 +377,5 @@ pointer usbCreatePrivate(DeviceIntPtr pDevice)
|
||||||
/** Destroy a private structure. */
|
/** Destroy a private structure. */
|
||||||
void usbDestroyPrivate(pointer priv)
|
void usbDestroyPrivate(pointer priv)
|
||||||
{
|
{
|
||||||
if (priv) xfree(priv);
|
if (priv) free(priv);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue