git: 12b92f3ed82a - main - bsdinstall: use the correct DISTDIR for fetching local distfiles

From: Kyle Evans <>
Date: Fri, 14 Oct 2022 05:26:23 UTC
The branch main has been updated by kevans:


commit 12b92f3ed82aa71c0eba246ce3053ef225724570
Author:     Kyle Evans <>
AuthorDate: 2022-10-14 05:22:09 +0000
Commit:     Kyle Evans <>
CommitDate: 2022-10-14 05:22:09 +0000

    bsdinstall: use the correct DISTDIR for fetching local distfiles
    fetchmissingdists naturally sets BSDINSTALL_DISTDIR to a directory in
    the new filesystem that it can write fetched distfiles to.  As a result,
    BSDINSTALL_DISTSITE was incorrectly set to the scratch space on /mnt for
    the call to distfetch when grabbing local distfiles, and it would
    subsequently fail.
    Switch to using the copy of BSDINSTALL_DISTDIR that we stashed off
    coming into fetchmissingdists; this one is in-fact set to the path where
    the local distfiles are stored.
    Patch suggested by jrtc27.
    Reported and tested by: Daniel O'Connor <darius dons net au>
    MFC after:      1 week
 usr.sbin/bsdinstall/scripts/fetchmissingdists | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/usr.sbin/bsdinstall/scripts/fetchmissingdists b/usr.sbin/bsdinstall/scripts/fetchmissingdists
index 586058272e71..a182ed517b75 100644
--- a/usr.sbin/bsdinstall/scripts/fetchmissingdists
+++ b/usr.sbin/bsdinstall/scripts/fetchmissingdists
@@ -88,7 +88,7 @@ fi
 if [ ! -z "$LOCAL_DISTRIBUTIONS" ]; then
 	# Copy local stuff first
 		bsdinstall distfetch || \
 		error "Failed to fetch distribution from local media"