Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f1688e04 authored by Dave Reisner's avatar Dave Reisner Committed by Greg Kroah-Hartman
Browse files

debugfs: convert gid= argument from decimal, not octal



This patch technically breaks userspace, but I suspect that anyone who
actually used this flag would have encountered this brokenness, declared
it lunacy, and already sent a patch.

Signed-off-by: default avatarDave Reisner <dreisner@archlinux.org>
Reviewed-by: default avatarVasiliy Kulikov <segoon@openwall.com>
Acked-by: default avatarKees Cook <keescook@chromium.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 54b956b9
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -176,7 +176,7 @@ static int debugfs_parse_options(char *data, struct debugfs_mount_opts *opts)
			opts->uid = uid;
			opts->uid = uid;
			break;
			break;
		case Opt_gid:
		case Opt_gid:
			if (match_octal(&args[0], &option))
			if (match_int(&args[0], &option))
				return -EINVAL;
				return -EINVAL;
			gid = make_kgid(current_user_ns(), option);
			gid = make_kgid(current_user_ns(), option);
			if (!gid_valid(gid))
			if (!gid_valid(gid))