Hi,
Please find simple patch which fixes problems with building apr-util
using Visual C++.
[[[
Fix the build on Windows.
* misc/apr_thread_pool.c (wait_on_busy_threads): Move variable declaration to
top of block.
]]]
--
Ivan Zhakov
Index: misc/apr_thread_pool.c
===================================================================
--- misc/apr_thread_pool.c (revision 533543)
+++ misc/apr_thread_pool.c (working copy)
@@ -599,13 +599,15 @@
apr_thread_mutex_lock(me->lock);
elt = APR_RING_FIRST(me->busy_thds);
while (elt != APR_RING_SENTINEL(me->busy_thds, apr_thread_list_elt, link))
{
+#ifndef NDEBUG
+ apr_os_thread_t *os_thread;
+#endif
if (elt->current_owner != owner) {
elt = APR_RING_NEXT(elt, link);
continue;
}
#ifndef NDEBUG
/* make sure the thread is not the one calling tasks_cancel */
- apr_os_thread_t *os_thread;
apr_os_thread_get(&os_thread, elt->thd);
#ifdef WIN32
/* hack for apr win32 bug */