diff options
author | rillig <rillig@pkgsrc.org> | 2008-01-20 19:55:29 +0000 |
---|---|---|
committer | rillig <rillig@pkgsrc.org> | 2008-01-20 19:55:29 +0000 |
commit | cb7ca2f08d7fed9eb12f2758f163e1676bd5ccc4 (patch) | |
tree | 4aee00a02c285087453f7dba5d45701407156801 /bootstrap | |
parent | d5340043570de3c79a07f0b331bca527814ef1fc (diff) | |
download | pkgsrc-cb7ca2f08d7fed9eb12f2758f163e1676bd5ccc4.tar.gz |
Make sure that the files found by check_prog are really regular files
and nothing else. This prevents bootstrap from exiting just because
there is a subdirectory named "awk" (or another tool) in one of the PATH
directories.
Fixes PR 37806.
Diffstat (limited to 'bootstrap')
-rwxr-xr-x | bootstrap/bootstrap | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/bootstrap/bootstrap b/bootstrap/bootstrap index eddc67216e2..04e3c77e63a 100755 --- a/bootstrap/bootstrap +++ b/bootstrap/bootstrap @@ -1,6 +1,6 @@ #! /bin/sh -# $NetBSD: bootstrap,v 1.116 2007/11/01 23:18:54 rillig Exp $ +# $NetBSD: bootstrap,v 1.117 2008/01/20 19:55:29 rillig Exp $ # # # Copyright (c) 2001-2002 Alistair G. Crooks. All rights reserved. @@ -170,7 +170,7 @@ check_prog() fi for _d in `echo $PATH | tr ':' ' '`; do - if [ -x "$_d/$_name" ]; then + if [ -f "$_d/$_name" ] && [ -x "$_d/$_name" ]; then # Program found eval $_var=\""$_d/$_name"\" return 1 |