Re: Custom C function - is palloc broken? - Mailing list pgsql-general

From Dan \"Heron\" Myers
Subject Re: Custom C function - is palloc broken?
Date
Msg-id 481FB769.7070808@xnapid.com
Whole thread Raw
In response to Custom C function - is palloc broken?  ("Nathan Thatcher" <n8thatcher@gmail.com>)
Responses Re: Custom C function - is palloc broken?  (Craig Ringer <craig@postnewspapers.com.au>)
Re: Custom C function - is palloc broken?  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
Craig Ringer wrote:
> I'm actually using a dummy header (just an empty file) for libintl.h .
> None of the involved module code actually uses anything from libintl,
> neither directly nor via any inlines/macros from postgresql's headers.
> I'm not even sure PostgreSQL needs to include the header in its own
> headers at all; it might be fine being included by the .c files. This
> shouldn't make any difference.

There are other files (such as netdb.h) which are also missing.  Do I
also need blank placeholder files for those to compile with VC++?  It
seems odd that they can compile PostgreSQL with Visual Studio (according
to Magnus, anyway) without several of the unix headers it depends on...
  and if they do, why don't they have some #ifdefs to check whether it's
building for windows and not include them if it is?

> - Is this with the original 8.3.1 binaries or custom ones built with
> MinGW and with NLS disabled?

The PostgreSQL binaries are the ones from the Windows installer.

> - Does it crash with the same error message & error code?

I don't get an error message per se...  The log file shows no errors,
but the query window I'm using (in pgadmin) loses its connection and
Visual Studio's just-in-time debugger pops up asking if I want to debug
postgres.exe... but if I say yes, it says it can't attach to the
process.  The crash is the same every time.

> - Are you testing with the source file I sent (that I know works) or
> with modified sources based on your original example?

I've tested both your file and mine, compiled with MinGW; both crash
every time I try any function.

- Dan

pgsql-general by date:

Previous
From: Craig Ringer
Date:
Subject: Re: Custom C function - is palloc broken?
Next
From: Craig Ringer
Date:
Subject: Re: Custom C function - is palloc broken?