Undo rate/period change after function body, so the damage doesn't leak
into other functions. (Debian #050)
This commit is contained in:
parent
bb5e934df7
commit
89c84575ea
|
@ -77,7 +77,9 @@ xf86GetKbdLeds()
|
|||
#include <asm/kbio.h>
|
||||
#endif
|
||||
|
||||
/* Deal with spurious kernel header change */
|
||||
/* Deal with spurious kernel header change in struct kbd_repeat.
|
||||
We undo this define after the routine using that struct is over,
|
||||
so as not to interfere with other 'rate' elements. */
|
||||
#if defined(LINUX_VERSION_CODE) && defined(KERNEL_VERSION)
|
||||
# if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,42)
|
||||
# define rate period
|
||||
|
@ -120,6 +122,13 @@ KDKBDREP_ioctl_ok(int rate, int delay) {
|
|||
|
||||
#undef rate
|
||||
|
||||
/* Undo the earlier define for the struct kbd_repeat problem. */
|
||||
#if defined(LINUX_VERSION_CODE) && defined(KERNEL_VERSION)
|
||||
# if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,42)
|
||||
# undef rate
|
||||
# endif
|
||||
#endif
|
||||
|
||||
static int
|
||||
KIOCSRATE_ioctl_ok(int rate, int delay) {
|
||||
#ifdef KIOCSRATE
|
||||
|
|
|
@ -107,7 +107,9 @@ GetKbdLeds(InputInfoPtr pInfo)
|
|||
#include <asm/kbio.h>
|
||||
#endif
|
||||
|
||||
/* Deal with spurious kernel header change */
|
||||
/* Deal with spurious kernel header change in struct kbd_repeat.
|
||||
We undo this define after the routine using that struct is over,
|
||||
so as not to interfere with other 'rate' elements. */
|
||||
#if defined(LINUX_VERSION_CODE) && defined(KERNEL_VERSION)
|
||||
# if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,42)
|
||||
# define rate period
|
||||
|
@ -151,6 +153,13 @@ KDKBDREP_ioctl_ok(int rate, int delay) {
|
|||
|
||||
#undef rate
|
||||
|
||||
/* Undo the earlier define for the struct kbd_repeat problem. */
|
||||
#if defined(LINUX_VERSION_CODE) && defined(KERNEL_VERSION)
|
||||
# if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,42)
|
||||
# undef rate
|
||||
# endif
|
||||
#endif
|
||||
|
||||
static int
|
||||
KIOCSRATE_ioctl_ok(int rate, int delay) {
|
||||
#ifdef KIOCSRATE
|
||||
|
@ -178,6 +187,8 @@ KIOCSRATE_ioctl_ok(int rate, int delay) {
|
|||
#endif /* KIOCSRATE */
|
||||
}
|
||||
|
||||
#undef rate
|
||||
|
||||
static void
|
||||
SetKbdRepeat(InputInfoPtr pInfo, char rad)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue