-const char jcc_rcs[] = "$Id: jcc.c,v 1.92.2.2 2002/11/20 14:37:47 oes Exp $";
+const char jcc_rcs[] = "$Id: jcc.c,v 1.92.2.3 2003/02/28 12:53:06 oes Exp $";
/*********************************************************************
*
* File : $Source: /cvsroot/ijbswa/current/Attic/jcc.c,v $
*
* Revisions :
* $Log: jcc.c,v $
+ * Revision 1.92.2.3 2003/02/28 12:53:06 oes
+ * Fixed two mostly harmless mem leaks
+ *
* Revision 1.92.2.2 2002/11/20 14:37:47 oes
* Fix: Head of global clients list now initialized to NULL
*
#define sleep(N) DosSleep(((N) * 100))
#endif
+#ifdef OSX_DARWIN
+/*
+ * Hit OSX over the head with a hammer. Protect all *_r functions.
+ */
+pthread_mutex_t gmtime_mutex;
+pthread_mutex_t localtime_mutex;
+pthread_mutex_t gethostbyaddr_mutex;
+pthread_mutex_t gethostbyname_mutex;
+#endif /* def OSX_DARWIN */
+
#if defined(unix) || defined(__EMX__)
const char *basedir;
const char *pidfile = NULL;
InitWin32();
#endif
+#ifdef OSX_DARWIN
+ /*
+ * Prepare global mutex semaphores
+ */
+ pthread_mutex_init(&gmtime_mutex,0);
+ pthread_mutex_init(&localtime_mutex,0);
+ pthread_mutex_init(&gethostbyaddr_mutex,0);
+ pthread_mutex_init(&gethostbyname_mutex,0);
+#endif /* def OSX_DARWIN */
+
/*
* Unix signal handling
*