summaryrefslogtreecommitdiff
path: root/libthreads
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>1994-05-05 10:52:06 +0000
committerRoland McGrath <roland@gnu.org>1994-05-05 10:52:06 +0000
commitec7b2ecc107401c0fe24fb738be0e6d031f0f622 (patch)
tree00dac0cd5c07e900aab53a52a7ae1a2f13c06105 /libthreads
parentae7701ab10bdfee2b3d0b0c272054333b24ea298 (diff)
entered into RCS
Diffstat (limited to 'libthreads')
-rw-r--r--libthreads/cthreads.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/libthreads/cthreads.h b/libthreads/cthreads.h
index d642ae9b..a7b09a1b 100644
--- a/libthreads/cthreads.h
+++ b/libthreads/cthreads.h
@@ -220,7 +220,12 @@ int NEVER;
*/
extern int cthread_init();
+#if 0
+/* This prototype is broken for GNU. */
extern any_t calloc C_ARG_DECLS((unsigned n, unsigned size));
+#else
+#include <stdlib.h>
+#endif
/*
* Queues.
@@ -320,7 +325,8 @@ typedef struct mutex {
struct cthread_queue queue;
} *mutex_t;
-#define MUTEX_INITIALIZER { SPIN_LOCK_INITIALIZER, 0, QUEUE_INITIALIZER, SPIN_LOCK_INITIALIZER}
+/* Rearranged accordingly for GNU: */
+#define MUTEX_INITIALIZER { SPIN_LOCK_INITIALIZER, SPIN_LOCK_INITIALIZER, 0, QUEUE_INITIALIZER }
#define mutex_alloc() ((mutex_t) calloc(1, sizeof(struct mutex)))
#define mutex_init(m) \