Skip to content

Commit

Permalink
Don't crash if LANG isn't set
Browse files Browse the repository at this point in the history
Chrome SSH doesn't set it.

Change-Id: Icc84ff8943a403db4b13f51727c6e83e5ccb5dab
  • Loading branch information
Brian authored and bsilver8192 committed Mar 11, 2017
1 parent ea56e21 commit fcf3ee7
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion tools/bazel
Original file line number Diff line number Diff line change
Expand Up @@ -81,11 +81,14 @@ ENVIRONMENT_VARIABLES+=(HOSTNAME="${HOSTNAME}")
ENVIRONMENT_VARIABLES+=(SHELL="${SHELL}")
ENVIRONMENT_VARIABLES+=(USER="${USER}")
ENVIRONMENT_VARIABLES+=(PATH="${PATH}")
ENVIRONMENT_VARIABLES+=(LANG="${LANG}")
ENVIRONMENT_VARIABLES+=(HOME="${HOME}")
ENVIRONMENT_VARIABLES+=(LOGNAME="${LOGNAME}")
ENVIRONMENT_VARIABLES+=(TERM="${TERM}")

if [[ ! -z "${LANG+x}" ]]; then
ENVIRONMENT_VARIABLES+=(LANG="${LANG}")
fi

if [[ ! -z "${DISPLAY+x}" ]]; then
ENVIRONMENT_VARIABLES+=(DISPLAY="${DISPLAY}")
fi
Expand Down

0 comments on commit fcf3ee7

Please sign in to comment.