Unix Technical Forum

Re: ECPG/OpenBSD buildfarm failures, take I

This is a discussion on Re: ECPG/OpenBSD buildfarm failures, take I within the pgsql Hackers forums, part of the PostgreSQL category; --> Michael Meskes wrote: > It seems ECPG regression tests trigger a bug in OpenBSD libc. Please try > the ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > pgsql Hackers

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-12-2008, 05:29 AM
Stefan Kaltenbrunner
 
Posts: n/a
Default Re: ECPG/OpenBSD buildfarm failures, take I

Michael Meskes wrote:
> It seems ECPG regression tests trigger a bug in OpenBSD libc. Please try
> the attached test case. I should give ERANGE as error, but on OpenBSD
> errno is set to 0.
>
> I tried this test case on Linux, where it works, and OpenBSD 3.8 and 4.0
> (that is HEAD). On both these systems it doesn't. Now the question is
> what do we do?


a bit of testing shows that at least FreeBSD 4.10 behaves similiar to
OpenBSD/i386 and I found the following discussion too:

http://docs.freebsd.org/cgi/getmsg.c...ebsd-standards


that hints that setting ERANGE on an underflow (vs an overflow) is
implementation specific though I ws unable to verify that this is indeed
the case ...


Stefan

---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-12-2008, 05:29 AM
Tom Lane
 
Posts: n/a
Default Re: ECPG/OpenBSD buildfarm failures, take I

Michael Fuhr <mike@fuhr.org> writes:
> In Plauger's _The Standard C Library_ (1992) on p 335 is an excerpt
> from the standard (I think). At the end of a section entitled
> "7.10.1.4 The strtod function" is the following: "If the correct
> value would cause underflow, zero is returned and the value of the
> macro ERANGE is stored in errno."


The Single Unix Spec also makes it clear that ERANGE on underflow is not
optional:
http://www.opengroup.org/onlinepubs/...sh/strtod.html

I think there is no question that OpenBSD is broken. The question for
us is whether we should expend effort to work around that. We already
have a "small-is-zero" workaround comparison file in the main regression
tests, so my thought is that ecpg should probably do likewise ...

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faq

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 07:00 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com