]> git.ipfire.org Git - thirdparty/autoconf.git/commitdiff
Fix awk script optimization.
authorRalf Wildenhues <Ralf.Wildenhues@gmx.de>
Fri, 23 Nov 2007 18:42:00 +0000 (19:42 +0100)
committerRalf Wildenhues <Ralf.Wildenhues@gmx.de>
Fri, 23 Nov 2007 18:42:00 +0000 (19:42 +0100)
* lib/autotest/general.m4 (AT_INIT): For awk line number
extraction script, ensure `$at_group' has a defined value
even for the empty set, and properly quote its usage inside
the awk script.

ChangeLog
lib/autotest/general.m4

index efc33d03b31263e245988f1fba90fe6c1284f0ff..d6d42ea887f6f3536a5e6cdbc4457558b0617804 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2007-11-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
+
+       * lib/autotest/general.m4 (AT_INIT): For awk line number
+       extraction script, ensure `$at_group' has a defined value
+       even for the empty set, and properly quote its usage inside
+       the awk script.
+
 2007-11-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
 
        * doc/autoconf.texi (Shell Functions): New chapter.  Document
index b40db8d12c5ffb77524d4292bee4dc07ee182264..6fa3f2e4cf380d2df529525c8f542df7e41834eb 100644 (file)
@@ -873,7 +873,7 @@ else
 fi
 
 # Get the last needed group.
-for at_group in $at_groups; do :; done
+for at_group in $at_groups; do :; done
 
 # Extract the start and end lines of each test group at the tail
 # of this file
@@ -885,7 +885,7 @@ BEGIN { FS="\a" }
 /^@%:@AT_STOP_/ {
   test = substr ($ 0, 10)
   print "at_sed" test "=\"1," start "d;" NR "q\""
-  if (test == '$at_group') exit
+  if (test == "'"$at_group"'") exit
 }' "$at_myself" > "$at_test_source"
 . "$at_test_source"