patch-2.1.118 linux/fs/devpts/inode.c

Next file: linux/fs/devpts/root.c
Previous file: linux/fs/devices.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.117/linux/fs/devpts/inode.c linux/fs/devpts/inode.c
@@ -77,13 +77,15 @@
 {
 	int setuid = 0;
 	int setgid = 0;
-	uid_t uid = 0;		/* To shut up gcc */
+	uid_t uid = 0;
 	gid_t gid = 0;
 	umode_t mode = 0600;
 	char *this_char, *value;
 
-	if ( !options ) return 1;
-	for (this_char = strtok(options,","); this_char; this_char = strtok(NULL,",")) {
+	this_char = NULL;
+	if ( options )
+		this_char = strtok(options,",");
+	for ( ; this_char; this_char = strtok(NULL,",")) {
 		if ((value = strchr(this_char,'=')) != NULL)
 			*value++ = 0;
 		if (!strcmp(this_char,"uid")) {

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