[or-cvs] r12768: Fix compilation when --disable-threads is passed in. (in tor/trunk: . src/common)
nickm at seul.org
nickm at seul.org
Tue Dec 11 23:06:51 UTC 2007
Author: nickm
Date: 2007-12-11 18:06:51 -0500 (Tue, 11 Dec 2007)
New Revision: 12768
Modified:
tor/trunk/
tor/trunk/ChangeLog
tor/trunk/src/common/compat.h
Log:
r17091 at catbus: nickm | 2007-12-11 18:05:55 -0500
Fix compilation when --disable-threads is passed in.
Property changes on: tor/trunk
___________________________________________________________________
svk:merge ticket from /tor/trunk [r17091] on 8246c3cf-6607-4228-993b-4d95d33730f1
Modified: tor/trunk/ChangeLog
===================================================================
--- tor/trunk/ChangeLog 2007-12-11 23:06:48 UTC (rev 12767)
+++ tor/trunk/ChangeLog 2007-12-11 23:06:51 UTC (rev 12768)
@@ -64,6 +64,7 @@
- Fix a couple of hard-to-trigger autoconf problems that could result
in really weird results on platforms whose sys/types.h files define
nonstandard integer types.
+ - Fix compilation with --disable-threads set.
o Minor features:
- On USR1, when dmalloc is in use, log the top 10 memory
Modified: tor/trunk/src/common/compat.h
===================================================================
--- tor/trunk/src/common/compat.h 2007-12-11 23:06:48 UTC (rev 12767)
+++ tor/trunk/src/common/compat.h 2007-12-11 23:06:51 UTC (rev 12768)
@@ -469,12 +469,14 @@
void tor_mutex_release(tor_mutex_t *m);
void tor_mutex_free(tor_mutex_t *m);
unsigned long tor_get_thread_id(void);
+void tor_threads_init(void);
#else
#define tor_mutex_new() ((tor_mutex_t*)tor_malloc(sizeof(int)))
#define tor_mutex_acquire(m) STMT_NIL
#define tor_mutex_release(m) STMT_NIL
#define tor_mutex_free(m) STMT_BEGIN tor_free(m); STMT_END
#define tor_get_thread_id() (1UL)
+#define tor_threads_init() STMT_NIL
#endif
#ifdef TOR_IS_MULTITHREADED
@@ -484,7 +486,6 @@
int tor_cond_wait(tor_cond_t *cond, tor_mutex_t *mutex);
void tor_cond_signal_one(tor_cond_t *cond);
void tor_cond_signal_all(tor_cond_t *cond);
-void tor_threads_init(void);
#endif
/* Platform-specific helpers. */
More information about the tor-commits
mailing list