patch-2.1.4 linux/fs/select.c

Next file: linux/fs/smbfs/inode.c
Previous file: linux/fs/readdir.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.3/linux/fs/select.c linux/fs/select.c
@@ -220,7 +220,7 @@
 		int error = verify_area(VERIFY_WRITE,fs_pointer,nr*sizeof(int));
 		if (!error) {
 			while (nr) {
-				*fdset = get_user(fs_pointer);
+				get_user(*fdset, fs_pointer);
 				nr--;
 				fs_pointer++;
 				fdset++;
@@ -301,8 +301,13 @@
 		error = verify_area(VERIFY_WRITE, tvp, sizeof(*tvp));
 		if (error)
 			goto out;
-		timeout = ROUND_UP(get_user(&tvp->tv_usec),(1000000/HZ));
-		timeout += get_user(&tvp->tv_sec) * (unsigned long) HZ;
+		get_user(timeout, &tvp->tv_usec);
+		timeout = ROUND_UP(timeout,(1000000/HZ));
+		{
+			unsigned long tmp;
+			get_user(tmp, &tvp->tv_sec);
+			timeout += tmp * (unsigned long) HZ;
+		}
 		if (timeout)
 			timeout += jiffies + 1;
 	}

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