Mailing List Archive

Re: [6.1] 2f2387038 Fix gensequences for BusyBox awk
--------

Why is this fix not in -trunk ?

Poul-Henning

In message <20181107091318.F3356ACEF1@lists.varnish-cache.org>, Pål Hermunn Johanse
n writes:
>
>commit 2f2387038a7b9aca4c31c0f839cda3b7ab3391c0
>Author: Guillaume Quintard <guillaume@varnish-software.com>
>Date: Thu Apr 26 21:59:41 2018 +0200
>
> Fix gensequences for BusyBox awk
>
> I never thought that I'd have to fix a string concatenation problem in
> a BusyBox awk program to generate VT100 code in a container, but here we
> are:
>
> echo | awk 'END {print "foo" "" ++a, "foo" ++a}'
>
> should output "foo0 foo1", and for all the ?awk I tested, it does,
> except for BusyBox awk who thought funny to output "0 foo1", breaking the
> teken_state.h file.
>
>diff --git a/bin/varnishtest/gensequences b/bin/varnishtest/gensequences
>index 4337186b8..18a68b43b 100644
>--- a/bin/varnishtest/gensequences
>+++ b/bin/varnishtest/gensequences
>@@ -70,7 +70,7 @@ while (getline > 0) {
> l_prefix_parent[n] = prefix;
> l_prefix_suffix[n] = sequence[i];
> if (!l_prefix_name[n])
>- l_prefix_name[n] = "teken_state_" ++npr;
>+ l_prefix_name[n] = "teken_state_" "" ++npr;
> prefix = n;
> }
>
>_______________________________________________
>varnish-commit mailing list
>varnish-commit@varnish-cache.org
>https://www.varnish-cache.org/lists/mailman/listinfo/varnish-commit
>

--
Poul-Henning Kamp | UNIX since Zilog Zeus 3.20
phk@FreeBSD.ORG | TCP/IP since RFC 956
FreeBSD committer | BSD since 4.3-tahoe
Never attribute to malice what can adequately be explained by incompetence.
_______________________________________________
varnish-dev mailing list
varnish-dev@varnish-cache.org
https://www.varnish-cache.org/lists/mailman/listinfo/varnish-dev
Re: [6.1] 2f2387038 Fix gensequences for BusyBox awk [ In reply to ]
On Wed, Nov 7, 2018 at 12:01 PM Poul-Henning Kamp <phk@phk.freebsd.dk> wrote:
>
> --------
>
> Why is this fix not in -trunk ?

It is:

$ git branch --contains 9f50c4bd12303674890ca742ce6b9592a29e3ba9
6.1
* master

But it was lost during backports. It was accidentally lost in both my
6.0 and Pål's 6.1 backports.

Dridi
_______________________________________________
varnish-dev mailing list
varnish-dev@varnish-cache.org
https://www.varnish-cache.org/lists/mailman/listinfo/varnish-dev
Re: [6.1] 2f2387038 Fix gensequences for BusyBox awk [ In reply to ]
> But it was lost during backports. It was accidentally lost in both my
> 6.0 and Pål's 6.1 backports.

I guess both Pål and I lost it because it was also lost in the mater branch:

$ git grep l_prefix_name -- bin/varnishtest/gensequences
<snip>
bin/varnishtest/gensequences: l_prefix_name[n] =
"teken_state_" ++npr;
<snip>

The change was overwritten in this commit:

commit f2abaf8698a34a44d8a80d80756b0f843560e31d
Author: Poul-Henning Kamp <phk@FreeBSD.org>
Date: Mon Sep 24 07:31:46 2018 +0000

Update Teken from FreeBSD source tree

phk, maybe you should upstream the fix to avoid running into the same
situation with the next teken update?

Dridi
_______________________________________________
varnish-dev mailing list
varnish-dev@varnish-cache.org
https://www.varnish-cache.org/lists/mailman/listinfo/varnish-dev