lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20070801222856.GA5692@schatzie.adilger.int>
Date:	Wed, 1 Aug 2007 16:28:56 -0600
From:	Andreas Dilger <adilger@...sterfs.com>
To:	Bernd Schubert <bschubert@...eap.de>
Cc:	linux-ext4@...r.kernel.org
Subject: Re: [PATCH] e2fsck/e2fsprogs: answer yes/no to a group of questions

On Aug 01, 2007  14:57 +0200, Bernd Schubert wrote:
> saying yes or no to all e2fsck questions can be rather annoying (yes I
> know -p and -y), so here's a patch to answer yes or no to a group of
> questions.

I've wanted something like this for quite a while already.

What would be more useful, however, is having the yes-to-all or no-to-all
apply to a particular problem instead of being generic.  Otherwise it
isn't really different from using -y or -n.  The reason that is useful
is that often there is a particular problem that should all be fixed or
skipped, but you want to be prompted how to fix a different problem type.

I haven't investigated, but maybe this could be implemented in the
same way as a latch for every problem?

> +	if (ptr->flags & PR_YES_TO_ALL) {
> +		printf("%s: yes\n", _(prompt[(int) ptr->prompt]));
> +		return YES;
> +	} else if (ptr->flags & PR_NO_TO_ALL) {
> +		printf("%s: no\n", _(prompt[(int) ptr->prompt]));
> +		return NO;
> +	}

The "yes" and "no" here should be "_("yes")" and "_("no")" like in
ask() so they are translated.

Cheers, Andreas
--
Andreas Dilger
Principal Software Engineer
Cluster File Systems, Inc.

-
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ