diff options
author | Raphael Geissert <geissert@debian.org> | 2013-03-10 19:52:59 +0000 |
---|---|---|
committer | Raphael Geissert <geissert@debian.org> | 2013-03-10 19:52:59 +0000 |
commit | 0eb29d89779509fd598692a564c734a9b7542770 (patch) | |
tree | a2e95bd3f48232d8b3c89db4a231a3cdaf4b0e54 /bin/gen-DSA | |
parent | af63bc8338964356eae0266e902a06f1b057a89a (diff) |
Drop leading blank space in CVE and bug numbers list
Additionally, "support" multiple bug numbers by correctly formatting
and generating a list of them.
git-svn-id: svn+ssh://svn.debian.org/svn/secure-testing@21568 e39458fd-73e7-0310-bf30-c45bca0a0e42
Diffstat (limited to 'bin/gen-DSA')
-rwxr-xr-x | bin/gen-DSA | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/bin/gen-DSA b/bin/gen-DSA index 794e3fdd52..f72115ce20 100755 --- a/bin/gen-DSA +++ b/bin/gen-DSA @@ -55,7 +55,7 @@ tolower() { } split_n_sort() { - printf '%s' "$1" | sed 's/[ ,;]+/ /g' | tr ' ' "\n" | sort -u | + printf '%s' "$1" | sed 's/[ ,;]+/ /g;s/^ //' | tr ' ' "\n" | sort -u | sort -n | tr "\n" ' ' | sed -r 's/\s+/ /g;s/\s$//' } @@ -174,6 +174,8 @@ while [ $# -gt 0 ]; do shift done +BUGNUM="$(split_n_sort "$BUGNUM")" + CVE="$(split_n_sort "$CVE")" cve_spacing= |