diff options
author | Bruce Momjian <bruce@momjian.us> | 2004-07-12 14:11:17 +0000 |
---|---|---|
committer | Bruce Momjian <bruce@momjian.us> | 2004-07-12 14:11:17 +0000 |
commit | a41463e31c4e3c231a84c47088e76d39191c4f36 (patch) | |
tree | 7844c4b346185ff74dcbe94d7b709e3d1da6018e /src/backend/access/gist/gistscan.c | |
parent | c14a43f657c33189582ca1a7a60ab419dc6164a5 (diff) | |
download | postgresql-a41463e31c4e3c231a84c47088e76d39191c4f36.tar.gz postgresql-a41463e31c4e3c231a84c47088e76d39191c4f36.zip |
win32 doesn't support a static initializer for mutexes, thus the first
user must initialize the lock. The problem are concurrent "first" users
- the pthread_mutex_t initialization must be synchronized.
The current implementation is broken, the attached patches fixes that:
mutex_initlock is a spinlock. If the pthread_mutex_t mutex is not
initialized, then the spinlock is acquired, if the pthread_mutex_t is
initialized if it's not yet initialized and then the spinlock is
dropped.
Manfred Spraul
Diffstat (limited to 'src/backend/access/gist/gistscan.c')
0 files changed, 0 insertions, 0 deletions