please review attached patch
From ec9cdfa848d438378919d4f8f2b1cba2a16f3eaa Mon Sep 17 00:00:00 2001 From: Ilya Shipitsin <[email protected]> Date: Sat, 24 Mar 2018 17:17:32 +0500 Subject: [PATCH] MINOR: fix build when USE_THREAD is not defined
src/queue.o: In function `pendconn_redistribute': /home/ilia/haproxy/src/queue.c:272: undefined reference to `thread_want_sync' src/queue.o: In function `pendconn_grab_from_px': /home/ilia/haproxy/src/queue.c:311: undefined reference to `thread_want_sync' src/queue.o: In function `process_srv_queue': /home/ilia/haproxy/src/queue.c:184: undefined reference to `thread_want_sync' collect2: error: ld returned 1 exit status make: *** [Makefile:900: haproxy] Error 1 --- src/queue.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/queue.c b/src/queue.c index 7cad813b..2dfee91e 100644 --- a/src/queue.c +++ b/src/queue.c @@ -180,8 +180,11 @@ void process_srv_queue(struct server *s) HA_SPIN_UNLOCK(SERVER_LOCK, &s->lock); HA_SPIN_UNLOCK(PROXY_LOCK, &p->lock); +#ifdef USE_THREAD if (remote) thread_want_sync(); +#endif + } /* Adds the stream <strm> to the pending connection list of server <strm>->srv @@ -268,8 +271,10 @@ int pendconn_redistribute(struct server *s) } HA_SPIN_UNLOCK(SERVER_LOCK, &s->lock); +#ifdef USE_THREAD if (remote) thread_want_sync(); +#endif return xferred; } @@ -307,8 +312,10 @@ int pendconn_grab_from_px(struct server *s) } HA_SPIN_UNLOCK(PROXY_LOCK, &s->proxy->lock); +#ifdef USE_THREAD if (remote) thread_want_sync(); +#endif return xferred; } -- 2.14.3

