This fixes warnings like this from gawk due to using an empty string
as the third argument:

gawk: cmd. line:9: (FILENAME=mytest.ii FNR=4) warning: gensub: third argument 
`' treated as 1

Committed as obvious.

commit 6ba6e37c3bfe88347a3b3e3069814c4d056bd469
Author: Jonathan Wakely <jwak...@redhat.com>
Date:   Tue Jan 19 21:54:48 2016 +0000

    	* uninclude: Fix third argument to gensub.

diff --git a/contrib/uninclude b/contrib/uninclude
index 8ba28e5..5612e65 100755
--- a/contrib/uninclude
+++ b/contrib/uninclude
@@ -38,7 +38,7 @@ BEGIN {
 !skipping && $0 ~ cppline && 
 (exclude == "" || $3 !~ exclude) && (include == "" || $3 ~ include) {
   skipping = 1;
-  printf "%s\n", "#include <" gensub(cppline, "\\2", "", $0) ">"
+  printf "%s\n", "#include <" gensub(cppline, "\\2", 1, $0) ">"
   next;
 }
 skipping && /^# [0-9]+ / && $3 == lastincluded {

Reply via email to