RE: [PATCH v2 0/6] Force pipes to flush immediately on NonStop platform
- From
Randall S. Becker <rsbecker@nexbridge.com>
- Date
- Jan 20, 2018, 13:23 UTC
- Message-ID
- <019501d391f1$e826f750$b874e5f0$@nexbridge.com>
- In-Reply-To
- <20180120111012.GA26459@tor.lan>
On January 20, 2018 6:10 AM, Torsten Bögershausen wrote:
Show 35 quoted lines
> On Fri, Jan 19, 2018 at 12:33:59PM -0500, randall.s.becker@rogers.com
> wrote:
> > From: "Randall S. Becker" <rsbecker@nexbridge.com>
> >
> > * wrapper.c: called setbuf(stream,0) to force pipe flushes not enabled by
> > default on the NonStop platform.
> >
> > Signed-off-by: Randall S. Becker <rsbecker@nexbridge.com>
> > ---
> > wrapper.c | 3 +++
> > 1 file changed, 3 insertions(+)
> >
> > diff --git a/wrapper.c b/wrapper.c
> > index d20356a77..671cbb4b4 100644
> > --- a/wrapper.c
> > +++ b/wrapper.c
> > @@ -403,6 +403,9 @@ FILE *xfdopen(int fd, const char *mode)
> > FILE *stream = fdopen(fd, mode);
> > if (stream == NULL)
> > die_errno("Out of memory? fdopen failed");
> > +#ifdef __TANDEM
> > + setbuf(stream,0);
> > +#endif
>
> Reading the commit message, I would have expected someting similar to
>
> #ifdef FORCE_PIPE_FLUSHES
> setbuf(stream,0);
> #endif
>
> (Because other systems may need the tweak as well, some day) Of course
> you need to change that in the Makefile and config.mak.uname
>
> > return stream;
> > }I can definitely see the point. Would you be agreeable to expanding the scope of this as a separate patch after this one is applied? I would want to bring at least one more Not NonStop machine into the mix for testing, which is more than I can do this weekend 😊.
Cheers, Randall