/* Condition variables for multithreading.
- Copyright (C) 2008 Free Software Foundation, Inc.
+ Copyright (C) 2008-2014 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software Foundation,
- Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */
+ along with this program; if not, see <http://www.gnu.org/licenses/>. */
/* Written by Yoann Vandoorselaere <yoann@prelude-ids.org>, 2008,
and Bruno Haible <bruno@clisp.org>, 2008. */
#include <config.h>
+#define _GLTHREAD_COND_INLINE _GL_EXTERN_INLINE
#include "glthread/cond.h"
/* ========================================================================= */
/* ========================================================================= */
-#if USE_WIN32_THREADS
+#if USE_WINDOWS_THREADS
#include <sys/time.h>
This field is immutable once initialized. */
};
-static inline void
+static void
gl_waitqueue_init (gl_waitqueue_t *wq)
{
wq->wq_list.wql_next = &wq->wq_list;
/* Removes the current thread, represented by a 'struct gl_waitqueue_element *',
from a wait queue.
Returns true if is was found and removed, false if it was not present. */
-static inline bool
+static bool
gl_waitqueue_remove (gl_waitqueue_t *wq, struct gl_waitqueue_element *elt)
{
if (elt->link.wql_next != NULL && elt->link.wql_prev != NULL)
}
/* Notifies the first thread from a wait queue and dequeues it. */
-static inline void
+static void
gl_waitqueue_notify_first (gl_waitqueue_t *wq)
{
if (wq->wq_list.wql_next != &wq->wq_list)
}
/* Notifies all threads from a wait queue and dequeues them all. */
-static inline void
+static void
gl_waitqueue_notify_all (gl_waitqueue_t *wq)
{
struct gl_waitqueue_link *l;