summaryrefslogtreecommitdiffstats
path: root/bin/gen-DSA
diff options
context:
space:
mode:
authorBen Hutchings <benh@debian.org>2017-01-03 20:05:53 +0000
committerBen Hutchings <benh@debian.org>2017-01-03 20:05:53 +0000
commitddfbbd6e246c322ca65285b58a361f58831769e6 (patch)
tree4c5911fc3b4825a40cda7454276ef65e1f9e3159 /bin/gen-DSA
parente3098d27cd868d9e791a1b923b13c1647f946713 (diff)
bin/gen-DSA: Fix sorting of CVE IDs with last part >= 10000
Use sort -V, which seems to do the right thing. git-svn-id: svn+ssh://svn.debian.org/svn/secure-testing@47702 e39458fd-73e7-0310-bf30-c45bca0a0e42
Diffstat (limited to 'bin/gen-DSA')
-rwxr-xr-xbin/gen-DSA4
1 files changed, 2 insertions, 2 deletions
diff --git a/bin/gen-DSA b/bin/gen-DSA
index 49e7d31fbd..da53bc1c70 100755
--- a/bin/gen-DSA
+++ b/bin/gen-DSA
@@ -80,7 +80,7 @@ tolower() {
split_n_sort() {
printf '%s' "$1" | sed -r 's/[ ,;]+/ /g;s/^ //' | tr ' ' "\n" | sort -u |
- sort -n | tr "\n" ' ' | sed -r 's/\s+/ /g;s/\s$//'
+ sort ${2:--n} | tr "\n" ' ' | sed -r 's/\s+/ /g;s/\s$//'
}
_d_space() {
@@ -185,7 +185,7 @@ done
BUGNUM="$(split_n_sort "$BUGNUM")"
-CVE="$(split_n_sort "$CVE")"
+CVE="$(split_n_sort "$CVE" -V)"
cve_spacing="$(right_space '' 17)"
sed_cmd='s/((CVE-[0-9-]+[ ]+){4})(.+)$/\1\\n'"$cve_spacing"'\3/g;P;D'

© 2014-2024 Faster IT GmbH | imprint | privacy policy