summaryrefslogtreecommitdiff
path: root/acconfig.h
diff options
context:
space:
mode:
authorrbb <rbb@13f79535-47bb-0310-9956-ffa450edef68>1999-10-14 17:39:03 +0000
committerrbb <rbb@13f79535-47bb-0310-9956-ffa450edef68>1999-10-14 17:39:03 +0000
commit365ccb9bb32a67b8bcec970d615fafed216a011f (patch)
tree11bcc36301f5dc8ec0760b394337f16aad7cc31d /acconfig.h
parent12a86b47bde16f4fd45351fdb5e1e3e35f691145 (diff)
downloadlibapr-365ccb9bb32a67b8bcec970d615fafed216a011f.tar.gz
Isolate the APR thread-safety macros. This makes any macro available to
ANY portion of APR. It also makes these macros internal to APR only, because this header file is not exposed to programs which use APR. git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@59349 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'acconfig.h')
-rw-r--r--acconfig.h34
1 files changed, 0 insertions, 34 deletions
diff --git a/acconfig.h b/acconfig.h
index 44a167a67..f53ae50cf 100644
--- a/acconfig.h
+++ b/acconfig.h
@@ -66,40 +66,6 @@ typedef void Sigfunc(int);
Sigfunc *signal(int signo, Sigfunc * func);
#endif
-#ifndef _POSIX_THREAD_SAFE_FUNCTIONS
-#define SAFETY_LOCK(func_name, cnt, name_str) \
- { \
- if (lock_##func_name == NULL) \
- if (ap_create_lock(&lock_##func_name, APR_MUTEX, APR_INTRAPROCESS, name_str, cnt) != APR_SUCCESS) \
- return APR_NOTTHREADSAFE; \
- if (ap_lock(lock_##func_name) != APR_SUCCESS) \
- return APR_NOTTHREADSAFE; \
- }
-#else
-#define SAFETY_LOCK(func_name, cnt)
-#endif
-
-#ifndef _POSIX_THREAD_SAFE_FUNCTIONS
-#define SAFETY_UNLOCK(func_name) \
- if (ap_unlock(lock_##func_name) != APR_SUCCESS) { \
- return APR_NOTTHREADSAFE; \
- }
-#else
-#define SAFETY_UNLOCK(func_name, cnt)
-#endif
-
-#ifdef HAVE_GMTIME_R
-#define GMTIME_R(x, y) gmtime_r(x, y)
-#else
-#define GMTIME_R(x, y) memcpy(y, gmtime(x), sizeof(y))
-#endif
-
-#ifdef HAVE_LOCALTIME_R
-#define LOCALTIME_R(x, y) localtime_r(x, y)
-#else
-#define LOCALTIME_R(x, y) memcpy(y, localtime(x), sizeof(y))
-#endif
-
#if !defined(HAVE_STRCASECMP) && defined(HAVE_STRICMP)
#define strcasecmp(s1,s2) stricmp(s1,s2)
#endif