Comment 1 for bug 771727

Revision history for this message
Jeroen T. Vermeulen (jtv) wrote :

As it turns out, it's not the split() that does it. LpQueryDistro deliberately doesn't even return the empty pocket suffix.

Disaster strikes in this bit of shell script that I converted incorrectly:

# Combine all supported series with all pocket suffixes to build the list
# of suites for which we will generate/update Contents.gz.
new_suites=
for suite in $suites; do
  new_suites="${new_suites:+$new_suites }$suite"
  for pocket_suffix in $pocket_suffixes; do
    if [ -d "$ARCHIVE/ubuntu/dists/$suite$pocket_suffix" ]; then
      new_suites="$new_suites $suite$pocket_suffix"
    fi
  done
done
suites="$new_suites"

This adds the $suite to $new_suites, and then for each non-empty pocket suffix adds $suite$pocket_suffix to $new_suites.