svn commit: r471273 - head/Mk/Scripts
Mathieu Arnold
mat at FreeBSD.org
Fri Jun 1 16:20:54 UTC 2018
Author: mat
Date: Fri Jun 1 16:20:51 2018
New Revision: 471273
URL: https://svnweb.freebsd.org/changeset/ports/471273
Log:
SC2155: Declare and assign separately to avoid masking return values.
In the original code, the return value of mycmd is ignored, and export
will instead always return true. This may prevent conditionals, set -e
and traps from working correctly.
PR: 227109
Submitted by: mat
Sponsored by: Absolight
Modified:
head/Mk/Scripts/smart_makepatch.sh (contents, props changed)
Modified: head/Mk/Scripts/smart_makepatch.sh
==============================================================================
--- head/Mk/Scripts/smart_makepatch.sh Fri Jun 1 16:20:48 2018 (r471272)
+++ head/Mk/Scripts/smart_makepatch.sh Fri Jun 1 16:20:51 2018 (r471273)
@@ -276,7 +276,8 @@ conserve_old_patches() {
}
install_regenerated_patches() {
- local testdir=$(find ${DESTDIR} -empty)
+ local testdir
+ testdir=$(find ${DESTDIR} -empty)
if [ -z "${testdir}" ]; then
mkdir -p ${PATCHDIR}
find ${DESTDIR} -type f -exec mv {} ${PATCHDIR}/ \;
More information about the svn-ports-all
mailing list