patch-2.1.13 linux/drivers/sound/sys_timer.c

Next file: linux/drivers/sound/uart6850.c
Previous file: linux/drivers/sound/sscape.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.12/linux/drivers/sound/sys_timer.c linux/drivers/sound/sys_timer.c
@@ -253,10 +253,15 @@
       break;
 
     case SNDCTL_SEQ_CTRLRATE:
-      if (ioctl_in (arg) != 0)	/* Can't change */
-	return -EINVAL;
+      {
+	int             val;
 
-      return ioctl_out (arg, ((curr_tempo * curr_timebase) + 30) / 60);
+	get_user (val, (int *) arg);
+	if (val != 0)		/* Can't change */
+	  return -EINVAL;
+
+	return ioctl_out (arg, ((curr_tempo * curr_timebase) + 30) / 60);
+      }
       break;
 
     case SNDCTL_SEQ_GETTIME:

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov