Re: Win32 regression tests

From: Claudio Natoli <claudio(dot)natoli(at)memetrics(dot)com>
To: 'Tom Lane' <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Claudio Natoli <claudio(dot)natoli(at)memetrics(dot)com>
Cc: 'pgsql-hackers-win32' <pgsql-hackers-win32(at)postgresql(dot)org>
Subject: Re: Win32 regression tests
Date: 2004-02-05 06:34:50
Message-ID: A02DEC4D1073D611BAE8525405FCCE2B55F2E3@harris.memetrics.local
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers-win32


Tom Lane writes:
> Claudio Natoli <claudio(dot)natoli(at)memetrics(dot)com> writes:
> > However, a number of tests fail purely because, for some reason, ERROR
> > messages seem to get printed out at the end of the test, instead of
where
> > expected, and sometimes with an extra blank line. I've included a few
> > examples below.
>
> > Anyway care to hazard a guess as to what the cause could be, and how to
> > correct?
>
> Lack of fflush(stderr) maybe?

Thanks for the hint. Lead me to try dropping in setvbuf(...,_IONBF,...)
calls, but to no avail.

Turns out it is another ming buffering issue, 'cause if I, say, run "make
installcheck" from Cygwin (with the postmaster running from either the Win32
command prompt, or mingw/msys), there's no such problem. Only occurs when
you run "make (install)check" from within ming/msys itself.

This is going to be really annoying for anyone developing the win32 port, at
least for as long as ming has these issues [sigh].

[On the plus side, the tests are running. "41 of 94 tests failed". Ok ok,
not great, until you do a quick scan over the results and see that almost
all of those that fail are for known issues; minor ones like %g/%e +
localtime differences, and major ones like deadlocking on rename/unlink]

> On Unix systems stderr is line-buffered and so it's seldom necessary to
> fflush it, but perhaps Windows gets this wrong (yawn...).

Then I guess you'll see some humour in the following, straight off the MSDN
for setvbuf:

_IOLBF
For some systems, this provides line buffering. However, for Win32, the
behavior is the same as _IOFBF - Full Buffering.

Again, thanks for the hint :-)
Claudio

---
Certain disclaimers and policies apply to all email sent from Memetrics.
For the full text of these disclaimers and policies see
<a
href="http://www.memetrics.com/emailpolicy.html">http://www.memetrics.com/em
ailpolicy.html</a>

Browse pgsql-hackers-win32 by date

  From Date Subject
Next Message Magnus Hagander 2004-02-05 09:08:44 Re: win32 signals, part 4
Previous Message Andrew Dunstan 2004-02-05 06:22:14 Re: Win32 regression tests