Skip site navigation (1) Skip section navigation (2)

Re: [HACKERS] Win32 WEXITSTATUS too

From: Magnus Hagander <magnus(at)hagander(dot)net>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: Takayuki Tsunakawa <tsunakawa(dot)takay(at)jp(dot)fujitsu(dot)com>,PostgreSQL-patches <pgsql-patches(at)postgresql(dot)org>,Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>,Alvaro Herrera <alvherre(at)commandprompt(dot)com>,ITAGAKI Takahiro <itagaki(dot)takahiro(at)oss(dot)ntt(dot)co(dot)jp>
Subject: Re: [HACKERS] Win32 WEXITSTATUS too
Date: 2007-01-23 15:07:43
Message-ID: 20070123150743.GA16185@svr2.hagander.net (view raw or flat)
Thread:
Lists: pgsql-hackerspgsql-patches
On Tue, Jan 23, 2007 at 09:29:19AM -0500, Bruce Momjian wrote:
> Magnus Hagander wrote:
> > On Tue, Jan 23, 2007 at 06:50:06PM +0900, Takayuki Tsunakawa wrote:
> > > From: "Magnus Hagander" <magnus(at)hagander(dot)net>
> > > > Are you entirely sure that ntstatus.h is where to look? Because per
> > > > whatever docs I've found, that contains "device driver errors" and
> > > *not*
> > > > exception codes.
> > > 
> > > Yes, what you are pointing out is correct.  winbase.h and winnt.h
> > > should be consulted instead of ntstatus.h.  See the the section
> > > "Return Value" in the following page:
> > > 
> > > http://msdn2.microsoft.com/ru-ru/library/ms679356.aspx
> > > 
> > > Furthermore, the message is meaningless for users because they can do
> > > nothing with the information.  So, I think the message should say
> > > something like
> > > 
> > > child process was terminated by exception %X
> > > This seems to be a bug of PostgreSQL.
> > > Please report this message with the details of the phynomenon to
> > > PostgreSQL developers.
> > > 
> > > 
> > > What do you think?
> > 
> > I think that's incorrect information to the user :-(
> > If the child terminates with exit(1), we will then say "child process
> > was terminated by exception 1. This seems to be a bug", which is clearly
> > not true.
> > 
> > Unless you know a sure way of determining if the exitcode is a normal
> > exitcode or an exception code.
> 
> Current CVS believes values >= 0x100 are non-exit() terminations.

Why does it do that :-) That's clearly wrong. There are plenty of
exitcodes > 0x100 that aren't exceptions.

//Magnus

In response to

Responses

pgsql-hackers by date

Next:From: Brian HurtDate: 2007-01-23 15:10:41
Subject: tripping an assert in 8.1.6
Previous:From: Tom LaneDate: 2007-01-23 15:03:24
Subject: Re: Piggybacking vacuum I/O

pgsql-patches by date

Next:From: Bruce MomjianDate: 2007-01-23 15:11:58
Subject: Re: [HACKERS] Win32 WEXITSTATUS too
Previous:From: Bruce MomjianDate: 2007-01-23 14:29:19
Subject: Re: [HACKERS] Win32 WEXITSTATUS too

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group