1 |
commit: c77e06ffac4dcc221b9cf8b6219d945ec0ae6ffa |
2 |
Author: Ulrich Müller <ulm <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sat Oct 10 22:17:15 2015 +0000 |
4 |
Commit: Ulrich Müller <ulm <AT> gentoo <DOT> org> |
5 |
CommitDate: Sat Oct 10 22:17:15 2015 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/qa-scripts.git/commit/?id=c77e06ff |
7 |
|
8 |
find-binary-files.sh: More false positives for GNU Info files. |
9 |
|
10 |
find-binary-files.sh | 7 ++++--- |
11 |
1 file changed, 4 insertions(+), 3 deletions(-) |
12 |
|
13 |
diff --git a/find-binary-files.sh b/find-binary-files.sh |
14 |
index ccff2d6..98346de 100755 |
15 |
--- a/find-binary-files.sh |
16 |
+++ b/find-binary-files.sh |
17 |
@@ -1,5 +1,5 @@ |
18 |
#!/bin/bash |
19 |
-# Copyright 2014 Gentoo Foundation |
20 |
+# Copyright 2014-2015 Gentoo Foundation |
21 |
# Distributed under the terms of the GNU GPL version 2 or later |
22 |
# Author: Ulrich Müller <ulm@g.o> |
23 |
|
24 |
@@ -21,9 +21,10 @@ find . \( -path ./distfiles -o -path ./local -o -path ./metadata \ |
25 |
# GNU Info files (or patches to them) can contain the following |
26 |
# control characters that produce false positives: |
27 |
# - 0x1f, followed by LF or FF |
28 |
- # - 0x7f (DEL), preceded by "Node:" in the same line |
29 |
+ # - 0x7f (DEL), preceded by "Node:" or "Ref:" in the same line |
30 |
# Filter such characters and reiterate |
31 |
- line=$(sed -e 's/\x1f\f\?$//;/Node:/s/\x7f//' "${path}" | file -i -) |
32 |
+ line=$(sed -e 's/\x1f\f\?$//;/\(Node\|Ref\):/s/\x7f//' "${path}" \ |
33 |
+ | file -i -) |
34 |
type=${line##*:*( )} |
35 |
;; |
36 |
esac |