Skip to contentSkip to conversation

BUGFIX - autofs4

PATCH New FabF 1 participant 1 message Apr 21, 2004

lore
Share & tools
lore

FabF

author
#0 lore raw

PATCH 1/1 BUGFIX - autofs4

Andrew,

Here's a bugfix against autofs4 (AFAICS, we parse_int to fd without
check) and parser optimization.

Could you apply ?

Regards,
Fabian

fs/autofs4/inode.c +3 -12
diff -Naur orig/fs/autofs4/inode.c edited/fs/autofs4/inode.c
@@ -132,34 +132,25 @@
 			continue;
 
 		token = match_token(p, tokens, args);
+		if (match_int(args, pipefd))
+			return 1;
 		switch (token) {
 		case Opt_fd:
-			if (match_int(args, pipefd))
-				return 1;
+			*pipefd = option;
 			break;
 		case Opt_uid:
-			if (match_int(args, &option))
-				return 1;
 			*uid = option;
 			break;
 		case Opt_gid:
-			if (match_int(args, &option))
-				return 1;
 			*gid = option;
 			break;
 		case Opt_pgrp:
-			if (match_int(args, &option))
-				return 1;
 			*pgrp = option;
 			break;
 		case Opt_minproto:
-			if (match_int(args, &option))
-				return 1;
 			*minproto = option;
 			break;
 		case Opt_maxproto:
-			if (match_int(args, &option))
-				return 1;
 			*maxproto = option;
 			break;
 		default: