From 2a59e976c18a796873614adaefe73689635b4fc9 Mon Sep 17 00:00:00 2001 From: Duncaen Date: Fri, 8 Nov 2019 18:48:25 +0100 Subject: [PATCH] xbps-src/chroot.sh: don't set empty PROXY environment variables --- common/xbps-src/shutils/chroot.sh | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/common/xbps-src/shutils/chroot.sh b/common/xbps-src/shutils/chroot.sh index 9c36a173255..8eac338a733 100644 --- a/common/xbps-src/shutils/chroot.sh +++ b/common/xbps-src/shutils/chroot.sh @@ -184,9 +184,12 @@ chroot_handler() { else env -i -- PATH="/usr/bin:$PATH" SHELL=/bin/sh \ HOME=/tmp IN_CHROOT=1 LC_COLLATE=C LANG=en_US.UTF-8 \ - HTTP_PROXY=${HTTP_PROXY} HTTPS_PROXY=${HTTPS_PROXY} \ - FTP_PROXY=${FTP_PROXY} SOCKS_PROXY=${SOCKS_PROXY} NO_PROXY=${NO_PROXY} \ - HTTP_PROXY_AUTH=${HTTP_PROXY_AUTH} \ + ${HTTP_PROXY:+HTTP_PROXY="${HTTP_PROXY}"} \ + ${HTTPS_PROXY:+HTTPS_PROXY="${HTTPS_PROXY}"} \ + ${FTP_PROXY:+FTP_PROXY="${FTP_PROXY}"} \ + ${SOCKS_PROXY:+SOCKS_PROXY="${SOCKS_PROXY}"} \ + ${NO_PROXY:+NO_PROXY="${NO_PROXY}"} \ + ${HTTP_PROXY_AUTH:+HTTP_PROXY_AUTH="${HTTP_PROXY_AUTH}"} \ SOURCE_DATE_EPOCH="$SOURCE_DATE_EPOCH" \ XBPS_ALLOW_CHROOT_BREAKOUT="$XBPS_ALLOW_CHROOT_BREAKOUT" \ $XBPS_COMMONDIR/chroot-style/${XBPS_CHROOT_CMD:=uunshare}.sh \