[PATCH evdev 2/2] Release leaked device identifier on input device disconnect.
Rami Ylimäki
rami.ylimaki at vincit.fi
Fri Mar 4 03:18:54 PST 2011
Signed-off-by: Rami Ylimäki <rami.ylimaki at vincit.fi>
Reviewed-by: Erkki Seppälä <erkki.seppala at vincit.fi>
---
src/evdev.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/src/evdev.c b/src/evdev.c
index a77be9e..165400f 100644
--- a/src/evdev.c
+++ b/src/evdev.c
@@ -1839,6 +1839,9 @@ EvdevUnInit(InputDriverPtr drv, InputInfoPtr pInfo, int flags)
free(pEvdev->rmlvo.variant);
free(pEvdev->rmlvo.options);
memset(&pEvdev->rmlvo, 0, sizeof(pEvdev->rmlvo));
+ /* Release string allocated in EvdevOpenDevice. */
+ free((void *)pEvdev->device); /* (const char *) */
+ pEvdev->device = NULL;
}
xf86DeleteInput(pInfo, flags);
}
--
1.6.3.3
More information about the xorg-devel
mailing list