summaryrefslogtreecommitdiff
path: root/admin/charsets
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2015-09-16 15:52:09 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2015-09-16 15:59:13 -0700
commitdc436dd77f70dbc2e294a1fd2d69a332f1413fa5 (patch)
tree84ba3af906962c65120fa1194b6908127d1a86a4 /admin/charsets
parent8865587c55f251ac624e6730505de66d15b28562 (diff)
downloademacs-dc436dd77f70dbc2e294a1fd2d69a332f1413fa5.tar.gz
Minor backslash fixes in manuals and scripts
* Makefile.in (install-arch-indep): * admin/charsets/compact.awk: * admin/charsets/gb180302.awk (gb_to_index): * admin/charsets/gb180304.awk (gb_to_index): Avoid undefined behavior in Awk regular expression backslashes. * doc/misc/efaq.texi (Matching parentheses): Omit unnecessary backslashes. * doc/misc/gnus-faq.texi (FAQ 5-8): Avoid undefined behavior in suggested sed backslash usage.
Diffstat (limited to 'admin/charsets')
-rw-r--r--admin/charsets/compact.awk3
-rw-r--r--admin/charsets/gb180302.awk5
-rw-r--r--admin/charsets/gb180304.awk5
3 files changed, 5 insertions, 8 deletions
diff --git a/admin/charsets/compact.awk b/admin/charsets/compact.awk
index b7d1fd19d8e..21e03ee4157 100644
--- a/admin/charsets/compact.awk
+++ b/admin/charsets/compact.awk
@@ -69,7 +69,7 @@ function decode_hex(str, idx) {
return n;
}
-/^\#/ {
+/^#/ {
print;
next;
}
@@ -119,4 +119,3 @@ END {
printf "0x%04X-0x%04X 0x%04X\n", from_code, to_code, from_unicode;
}
}
-
diff --git a/admin/charsets/gb180302.awk b/admin/charsets/gb180302.awk
index 40d92bf9be4..4947f966371 100644
--- a/admin/charsets/gb180302.awk
+++ b/admin/charsets/gb180302.awk
@@ -53,7 +53,7 @@ function decode_hex(str) {
function gb_to_index(gb) {
b0 = int(gb / 256);
b1 = gb % 256;
- idx = (((b0 - 129)) * 191 + b1 - 64);
+ idx = (((b0 - 129)) * 191 + b1 - 64);
# if (b1 >= 128)
# idx--;
return idx
@@ -67,7 +67,7 @@ function index_to_gb(idx) {
return (b0 * 256 + b1);
}
-/^\#/ {
+/^#/ {
print;
next;
}
@@ -108,4 +108,3 @@ END {
printf "0x%04X-0x%04X 0x%04X\n",
index_to_gb(from_gb), index_to_gb(to_gb), from_unicode;
}
-
diff --git a/admin/charsets/gb180304.awk b/admin/charsets/gb180304.awk
index 3c16cb556ea..81d7e7301bf 100644
--- a/admin/charsets/gb180304.awk
+++ b/admin/charsets/gb180304.awk
@@ -49,7 +49,7 @@ function decode_hex(str) {
function gb_to_index(gb) {
b0 = int(gb / 256);
b1 = gb % 256;
- idx = (((b0 - 129)) * 191 + b1 - 64);
+ idx = (((b0 - 129)) * 191 + b1 - 64);
# if (b1 >= 127)
# idx--;
return idx
@@ -65,7 +65,7 @@ function index_to_gb(idx) {
return sprintf("%02X%02X%02X%02X", b0, b1, b2, b3);
}
-/^\#/ {
+/^#/ {
print;
next;
}
@@ -119,4 +119,3 @@ END {
}
}
}
-