Re: windows consolidated cleanup
Andrew Dunstan <andrew@dunslane.net>
From: Andrew Dunstan <andrew@dunslane.net>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: PostgreSQL-development <pgsql-hackers@postgresql.org>
Date: 2011-04-24T17:35:06Z
Lists: pgsql-hackers
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Move include for Python.h above postgres.h to eliminate compiler warning.
- ab6ee1f9fc70 8.0.0 cited
On 04/24/2011 12:25 PM, Tom Lane wrote: > Andrew Dunstan<andrew@dunslane.net> writes: >> The attached patch is intended to clean up a bunch of compiler warnings >> seen on Windows due to mismatches of signedness or constness, unused >> variables, redefined macros and a missing prototype. > BTW, this hunk: > > [snip] > is indicative of far worse problems than the one it claims to solve. > This file is in fundamental violation of the first commandment of > Postgres #includes, which is "thou shalt have no other gods before c.h". > We need to put postgres.h *before* the Python.h include. I don't know > what issues led to the current arrangement but it is fraught with > portability gotchas. In particular it's just about guaranteed to fail > on platforms where<stdio.h> reacts to _FILE_OFFSET_BITS --- plpython.c > is going to get compiled expecting a different stdio library than the > rest of the backend. > > Well, I certainly noticed that postgres.h wasn't first, but assumed it had been sanctioned long ago. It's been that way for a long time. I'll leave that bit out of this cleanup, but we should look at this whole mess separately ASAP. cheers andrew