Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 10 Sep 2023 05:51:43 -0600
From:      Warner Losh <imp@bsdimp.com>
To:        Robert Clausecker <fuz@fuz.su>
Cc:        FreeBSD Current <current@freebsd.org>
Subject:   Re: sed in CURRENT fails in textproc/jq
Message-ID:  <CANCZdfpesLu%2B5YLB4-irR7XSSSM1wXPLH58TbefPzvGo=q1xgg@mail.gmail.com>
In-Reply-To: <ZP1LPZcC99zIS1Jp@fuz.su>
References:  <30a59ac0-28fd-f6ed-505c-9ef6d8e84fc3@tsoft.com> <CAALwa8kAaDw80h2cbaeLOmw2G9EpRo6dJFZcFFc99mAU_7xkRA@mail.gmail.com> <86edj7qnia.fsf@ltc.des.no> <ZP1LPZcC99zIS1Jp@fuz.su>

next in thread | previous in thread | raw e-mail | index | archive | help
--000000000000151a540604ffd64c
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

On Sat, Sep 9, 2023, 10:51 PM Robert Clausecker <fuz@fuz.su> wrote:

> Greetings,
>
> I apologise for the inconvenience.  The issue seems to boil down to
> various places calling
>
>     memchr(buf, c, SIZE_MAX);
>
> which causes an overflow when my newly written memchr() computes buf +
> len to find the end of the buffer.  A patch to alleviate this issue can
> be found here:
>
>
> http://fuz.su/~fuz/freebsd/0001-lib-libc-amd64-string-memchr.S-fix-behavi=
our-with-ov.patch
>
> Please check if it does the trick for you.  If yes, I'll go ahead and
> push it tomorrow-ish.
>


There are half a dozen or do kyua tests that are likely failing because of
this or other reasons related to strings.  When you push this fix you'll
get the list. They are hidden among about 80 or so networking tests that
fail. I plan on disabling those tests soon If no one fixes them.

Warner

>
> Yours,
> Robert Clausecker
>
> Am Sat, Sep 09, 2023 at 07:12:29PM +0200 schrieb Dag-Erling Sm=C3=B8rgrav=
:
> > Antoine Brodin <antoine@freebsd.org> writes:
> > > Yuri <yuri@freebsd.org> writes:
> > > > Either something has changed in sed(1) in CURRENT, or sed just fail=
s
> > > > during the configure stage of textproc/jq:
> > > >
> > > > sed: No error: 0
> > > > checking for sys/cygwin.h... eval: ${+...}: Bad substitution
> > > This seems to be a recent issue (less than 5 days).
> > > Hundreds of configure scripts now fail to run on 15-current due to
> > > this sed failure: [...]
> >
> > Try adding ARCHLEVEL=3Dscalar to CONFIGURE_ENV on one of these.  If tha=
t
> > helps, yell at fuz@ :)
> >
> > DES
> > --
> > Dag-Erling Sm=C3=B8rgrav - des@FreeBSD.org
> >
>
> --
> ()  ascii ribbon campaign - for an 8-bit clean world
> /\  - against html email  - against proprietary attachments
>
>

--000000000000151a540604ffd64c
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"auto"><div><br><br><div class=3D"gmail_quote"><div dir=3D"ltr" =
class=3D"gmail_attr">On Sat, Sep 9, 2023, 10:51 PM Robert Clausecker &lt;<a=
 href=3D"mailto:fuz@fuz.su">fuz@fuz.su</a>&gt; wrote:<br></div><blockquote =
class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid=
;padding-left:1ex">Greetings,<br>
<br>
I apologise for the inconvenience.=C2=A0 The issue seems to boil down to<br=
>
various places calling<br>
<br>
=C2=A0 =C2=A0 memchr(buf, c, SIZE_MAX);<br>
<br>
which causes an overflow when my newly written memchr() computes buf +<br>
len to find the end of the buffer.=C2=A0 A patch to alleviate this issue ca=
n<br>
be found here:<br>
<br>
=C2=A0 =C2=A0 <a href=3D"http://fuz.su/~fuz/freebsd/0001-lib-libc-amd64-str=
ing-memchr.S-fix-behaviour-with-ov.patch" rel=3D"noreferrer noreferrer" tar=
get=3D"_blank">http://fuz.su/~fuz/freebsd/0001-lib-libc-amd64-string-memchr=
.S-fix-behaviour-with-ov.patch</a><br>
<br>
Please check if it does the trick for you.=C2=A0 If yes, I&#39;ll go ahead =
and<br>
push it tomorrow-ish.<br></blockquote></div></div><div dir=3D"auto"><br></d=
iv><div dir=3D"auto"><br></div><div dir=3D"auto">There are half a dozen or =
do kyua tests that are likely failing because of this or other reasons rela=
ted to strings.=C2=A0 When you push this fix you&#39;ll get the list. They =
are hidden among about 80 or so networking tests that fail. I plan on disab=
ling those tests soon If no one fixes them.</div><div dir=3D"auto"><br></di=
v><div dir=3D"auto">Warner=C2=A0</div><div dir=3D"auto"><div class=3D"gmail=
_quote"><blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border=
-left:1px #ccc solid;padding-left:1ex">
<br>
Yours,<br>
Robert Clausecker<br>
<br>
Am Sat, Sep 09, 2023 at 07:12:29PM +0200 schrieb Dag-Erling Sm=C3=B8rgrav:<=
br>
&gt; Antoine Brodin &lt;<a href=3D"mailto:antoine@freebsd.org" target=3D"_b=
lank" rel=3D"noreferrer">antoine@freebsd.org</a>&gt; writes:<br>
&gt; &gt; Yuri &lt;<a href=3D"mailto:yuri@freebsd.org" target=3D"_blank" re=
l=3D"noreferrer">yuri@freebsd.org</a>&gt; writes:<br>
&gt; &gt; &gt; Either something has changed in sed(1) in CURRENT, or sed ju=
st fails<br>
&gt; &gt; &gt; during the configure stage of textproc/jq:<br>
&gt; &gt; &gt;<br>
&gt; &gt; &gt; sed: No error: 0<br>
&gt; &gt; &gt; checking for sys/cygwin.h... eval: ${+...}: Bad substitution=
<br>
&gt; &gt; This seems to be a recent issue (less than 5 days).<br>
&gt; &gt; Hundreds of configure scripts now fail to run on 15-current due t=
o<br>
&gt; &gt; this sed failure: [...]<br>
&gt; <br>
&gt; Try adding ARCHLEVEL=3Dscalar to CONFIGURE_ENV on one of these.=C2=A0 =
If that<br>
&gt; helps, yell at fuz@ :)<br>
&gt; <br>
&gt; DES<br>
&gt; -- <br>
&gt; Dag-Erling Sm=C3=B8rgrav - des@FreeBSD.org<br>
&gt; <br>
<br>
-- <br>
()=C2=A0 ascii ribbon campaign - for an 8-bit clean world <br>
/\=C2=A0 - against html email=C2=A0 - against proprietary attachments<br>
<br>
</blockquote></div></div></div>

--000000000000151a540604ffd64c--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CANCZdfpesLu%2B5YLB4-irR7XSSSM1wXPLH58TbefPzvGo=q1xgg>