At 2:46 PM -0500 12/5/00, Tom Lane wrote:
>Hm. It's clearly possible to base Postgres's semaphore stuff on unnamed
>Posix semaphores living in the shared memory area (which eliminates the
>issue of inheritance by child processes). You'd need to revise the API
>presented by ipc.c so that it doesn't depend on semaphore IDs and keys.
Heh. True, but unfortunately Apple hasn't implemented _unnamed_ POSIX semaphores yet. (Please don't shoot the messenger, I'll kill myself.)
But my patch to ipc.c to use named semaphores is actually pretty compact. It conditionalizes the function bodies of IpcSemaphoreLock and related, and it changes the typedef of a IpcSemaphoreId from a int to a long, so I just pass the key used to create the semaphore back as the semid.
"Every time you provide an option, you're asking the user to make a decision.
That means they will have to think about something and decide about it.
It's not necessarily a bad thing, but, in general, you should always try to
minimize the number of decisions that people have to make."
In response to
pgsql-patches by date
|Next:||From: Michael Fork||Date: 2000-12-06 05:00:09|
|Subject: Diff to fix SQLForeignKeys in ODBC|
|Previous:||From: Peter Eisentraut||Date: 2000-12-05 21:48:39|
|Subject: Re: darwin pgsql patches |