From 77398c759e542e1b8702da35c886c85c3f0f8a1b Mon Sep 17 00:00:00 2001 From: Federico Di Gregorio Date: Sat, 11 Feb 2006 11:01:17 +0000 Subject: [PATCH] Fixed handle leak on win32 and preparing 2.0 beta 8. --- ChangeLog | 7 +++++++ NEWS | 5 +++++ psycopg/config.h | 2 +- 3 files changed, 13 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 489cf253..ade80ada 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2006-02-11 Federico Di Gregorio + + * Release 2.0 beta 8. + + * psycopg/config.h: applied patch from Jason to fix handle leak on + win32, as documented in #92. + 2006-02-11 Federico Di Gregorio * Release 2.0 beta 7. diff --git a/NEWS b/NEWS index 9abd066a..a400b90b 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,8 @@ +What's new in psycopg 2.0 beta 8 +-------------------------------- + +* Fixed handle leak on win32. + What's new in psycopg 2.0 beta 7 -------------------------------- diff --git a/psycopg/config.h b/psycopg/config.h index f222fd90..649fee8b 100644 --- a/psycopg/config.h +++ b/psycopg/config.h @@ -57,7 +57,7 @@ static void Dprintf(const char *fmt, ...) {} #define pthread_condvar_t HANDLE #define pthread_mutex_lock(object) WaitForSingleObject(object, INFINITE) #define pthread_mutex_unlock(object) ReleaseMutex(object) -#define pthread_mutex_destroy(ref) (CloseHandle(ref)) +#define pthread_mutex_destroy(ref) (CloseHandle(*(ref))) /* convert pthread mutex to native mutex */ static int pthread_mutex_init(pthread_mutex_t *mutex, void* fake) {