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] [day] [month] [year] [list]
Date:	Thu, 20 Aug 2015 14:06:31 +0200
From:	Michal Marek <mmarek@...e.cz>
To:	Sam Bobroff <sam.bobroff@....ibm.com>
Cc:	linux-kernel@...r.kernel.org, linux-kbuild@...r.kernel.org
Subject: Re: [PATCH v2 1/1] merge_config.sh: exit on missing input files

On 2015-07-20 07:12, Sam Bobroff wrote:
> Add a check for the existence of input files and exit (with failure)
> if they are missing.
> 
> Without this additional check, missing files produce error messages
> but still result in an output file being generated and a successful
> exit code.
> 
> Signed-off-by: Sam Bobroff <sam.bobroff@....ibm.com>

Thanks, applied to kbuild.git#kconfig.


> Additionally, it seems like it might be a good idea (either with or
> without this patch) to add "set -e" to the script because this patch
> only handles missing files, not other errors (which will currently be
> ignored and return a successful exit code). Should I add this to the
> patch?

I'd prefer proper error handling over set -e. set -e usually bites you
when you expect it the least, e.g. inside the loop at the end of the script:

	REQUESTED_VAL=$(grep -w -e "$CFG" $TMP_FILE)
	ACTUAL_VAL=$(grep -w -e "$CFG" $OUTPUT/.config)

The second grep call can return 1, but in this case we want to report
the difference.

Michal
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ