diff options
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | profile.c | 4 | ||||
-rw-r--r-- | test/ChangeLog | 5 | ||||
-rw-r--r-- | test/Makefile.am | 9 | ||||
-rw-r--r-- | test/Makefile.in | 9 | ||||
-rw-r--r-- | test/genpot.awk | 1 | ||||
-rw-r--r-- | test/genpot.ok | 5 |
7 files changed, 35 insertions, 4 deletions
@@ -1,3 +1,9 @@ +2014-10-04 Arnold D. Robbins <arnold@skeeve.com> + + * profile.c (pp_string_fp): Fix breaklines case to actually + output the current letter. This broke at gawk 4.0.0. Sigh. + Thanks to Bert Bos (bert@w3.org) for the report. + 2014-09-29 Andrew J. Schorr <aschorr@telemetry-investments.com> * main.c (main): In optlist, it should say "h", not "h:", since there @@ -909,11 +909,11 @@ pp_string_fp(Func_print print_func, FILE *fp, const char *in_str, slen = strlen(str); for (count = 0; slen > 0; slen--, str++) { + print_func(fp, "%c", *str); if (++count >= BREAKPOINT && breaklines) { print_func(fp, "%c\n%c", delim, delim); count = 0; - } else - print_func(fp, "%c", *str); + } } efree(s); } diff --git a/test/ChangeLog b/test/ChangeLog index b221bf2f..3615b954 100644 --- a/test/ChangeLog +++ b/test/ChangeLog @@ -1,3 +1,8 @@ +2014-10-04 Arnold D. Robbins <arnold@skeeve.com> + + * Makefile.am (genpot): New test. + * genpot.awk, genpot.ok: New files. + 2014-09-29 Arnold D. Robbins <arnold@skeeve.com> * testext.ok: Adjusted after minor code change. diff --git a/test/Makefile.am b/test/Makefile.am index 1c14ea81..e547fe2c 100644 --- a/test/Makefile.am +++ b/test/Makefile.am @@ -324,6 +324,8 @@ EXTRA_DIST = \ fwtest3.awk \ fwtest3.in \ fwtest3.ok \ + genpot.awk \ + genpot.ok \ gensub.awk \ gensub.in \ gensub.ok \ @@ -1009,7 +1011,7 @@ GAWK_EXT_TESTS = \ colonwarn clos1way dbugeval delsub devfd devfd1 devfd2 dumpvars exit \ fieldwdth fpat1 fpat2 fpat3 fpatnull fsfwfs funlen \ functab1 functab2 functab3 fwtest fwtest2 fwtest3 \ - gensub gensub2 getlndir gnuops2 gnuops3 gnureops \ + genpot gensub gensub2 getlndir gnuops2 gnuops3 gnureops \ icasefs icasers id igncdym igncfs ignrcas2 ignrcase \ incdupe incdupe2 incdupe3 incdupe4 incdupe5 incdupe6 incdupe7 \ include include2 indirectcall indirectcall2 \ @@ -1977,6 +1979,11 @@ filefuncs: @AWKPATH="$(srcdir)" $(AWK) -f $@.awk -v builddir="$(abs_top_builddir)" >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) "$(srcdir)"/$@.ok _$@ && rm -f _$@ +genpot: + @echo $@ + @AWKPATH="$(srcdir)" $(AWK) -f $@.awk --gen-pot >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) "$(srcdir)"/$@.ok _$@ && rm -f _$@ + # Targets generated for other tests: include Maketests diff --git a/test/Makefile.in b/test/Makefile.in index b7e25511..a155f14c 100644 --- a/test/Makefile.in +++ b/test/Makefile.in @@ -570,6 +570,8 @@ EXTRA_DIST = \ fwtest3.awk \ fwtest3.in \ fwtest3.ok \ + genpot.awk \ + genpot.ok \ gensub.awk \ gensub.in \ gensub.ok \ @@ -1254,7 +1256,7 @@ GAWK_EXT_TESTS = \ colonwarn clos1way dbugeval delsub devfd devfd1 devfd2 dumpvars exit \ fieldwdth fpat1 fpat2 fpat3 fpatnull fsfwfs funlen \ functab1 functab2 functab3 fwtest fwtest2 fwtest3 \ - gensub gensub2 getlndir gnuops2 gnuops3 gnureops \ + genpot gensub gensub2 getlndir gnuops2 gnuops3 gnureops \ icasefs icasers id igncdym igncfs ignrcas2 ignrcase \ incdupe incdupe2 incdupe3 incdupe4 incdupe5 incdupe6 incdupe7 \ include include2 indirectcall indirectcall2 \ @@ -2399,6 +2401,11 @@ filefuncs: @echo $@ @AWKPATH="$(srcdir)" $(AWK) -f $@.awk -v builddir="$(abs_top_builddir)" >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) "$(srcdir)"/$@.ok _$@ && rm -f _$@ + +genpot: + @echo $@ + @AWKPATH="$(srcdir)" $(AWK) -f $@.awk --gen-pot >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) "$(srcdir)"/$@.ok _$@ && rm -f _$@ Gt-dummy: # file Maketests, generated from Makefile.am by the Gentests program addcomma: diff --git a/test/genpot.awk b/test/genpot.awk new file mode 100644 index 00000000..990b0b5c --- /dev/null +++ b/test/genpot.awk @@ -0,0 +1 @@ +{print _"This string is so long that gawk --gen-pot will break it and lose a letter at the break."} diff --git a/test/genpot.ok b/test/genpot.ok new file mode 100644 index 00000000..35c0cc99 --- /dev/null +++ b/test/genpot.ok @@ -0,0 +1,5 @@ +#: genpot.awk:1 +msgid "This string is so long that gawk --gen-pot will break it and lose a l" +"etter at the break." +msgstr "" + |