Skip to content
This repository has been archived by the owner on Apr 21, 2023. It is now read-only.


Browse files Browse the repository at this point in the history
Linux installer: Fix APT_SOURCES and APT_SOURCESDIR paths
In prior versions of Ubuntu/Debian the Dir::Etc apt-config variable contained a
trailing slash by default. The cronjob at /etc/cron.daily/google-chrome was
concatenating that variable into a path, assuming the trailing slash. But in
Ubuntu 16.10, the trailing slash is gone. That breaks the path to the list file,
and the cronjob fails to fix it.

Patch from

Fixes #1428
  • Loading branch information
jeffkaufman committed Nov 10, 2016
1 parent e472a0f commit 36d4a38
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions install/common/apt.include
Expand Up @@ -124,10 +124,14 @@ KEYDATA

# Set variables for the locations of the apt sources lists.
find_apt_sources() {
# NB: These variables only *sometimes* include a trailing slash. (In
# particular, in Ubuntu 16.10 / Debian 9, the default value *stopped*
# including the trailing slash.) We have to join them with slashes, even
# though that sometimes gives a double slash.
APTDIR=$(apt_config_val Dir)
APTETC=$(apt_config_val 'Dir::Etc')
APT_SOURCES="$APTDIR$APTETC$(apt_config_val 'Dir::Etc::sourcelist')"
APT_SOURCESDIR="$APTDIR$APTETC$(apt_config_val 'Dir::Etc::sourceparts')"
APT_SOURCES="$APTDIR/$APTETC/$(apt_config_val 'Dir::Etc::sourcelist')"
APT_SOURCESDIR="$APTDIR/$APTETC/$(apt_config_val 'Dir::Etc::sourceparts')"

# Update the Google repository if it's not set correctly.
Expand Down

0 comments on commit 36d4a38

Please sign in to comment.