Date: Fri, 1 Jun 2018 16:20:51 +0000 (UTC) From: Mathieu Arnold <mat@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r471273 - head/Mk/Scripts Message-ID: <201806011620.w51GKpZD004514@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
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}/ \;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201806011620.w51GKpZD004514>