Re: new compiler warnings

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
Cc: "Robert Haas" <robertmhaas(at)gmail(dot)com>, "Andrew Dunstan" <andrew(at)dunslane(dot)net>, "Peter Eisentraut" <peter_e(at)gmx(dot)net>, pgsql(at)j-davis(dot)com, pgsql-hackers(at)postgresql(dot)org
Subject: Re: new compiler warnings
Date: 2011-10-18 20:28:16
Message-ID: 21875.1318969696@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

"Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov> writes:
> Would it be too weird to do something like this for each?:

> - write(fileno(stderr), line, len);
> + rc = write(fileno(stderr), line, len);
> + if (rc >= 0 && rc != len)
> + {
> + Assert(false);
> + return;
> + }

I don't think the assert is a good idea. If it ever did happen, that
would promote the problem from "corrupted data in the log" to "database
crash".

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Kevin Grittner 2011-10-18 20:34:18 Re: new compiler warnings
Previous Message Robert Haas 2011-10-18 20:27:59 Re: new compiler warnings