From: Olivier Houchard Date: Wed, 1 Nov 2017 12:55:10 +0000 (+0100) Subject: MINOR: mux: Only define pipe functions on linux. X-Git-Tag: v1.8-rc2~17 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=7da120bb0e8b24e2d9878e2a719d4863ff5af596;p=thirdparty%2Fhaproxy.git MINOR: mux: Only define pipe functions on linux. Only define mux_pt_snd_pipe() and mux_pt_rcv_pipe() if splicing is available. --- diff --git a/src/mux_pt.c b/src/mux_pt.c index 54244c34ef..479f831c69 100644 --- a/src/mux_pt.c +++ b/src/mux_pt.c @@ -170,6 +170,7 @@ static int mux_pt_snd_buf(struct conn_stream *cs, struct buffer *buf, int flags) return (cs->conn->xprt->snd_buf(cs->conn, buf, flags)); } +#if defined(CONFIG_HAP_LINUX_SPLICE) /* Send and get, using splicing */ static int mux_pt_rcv_pipe(struct conn_stream *cs, struct pipe *pipe, unsigned int count) { @@ -187,6 +188,7 @@ static int mux_pt_snd_pipe(struct conn_stream *cs, struct pipe *pipe) { return (cs->conn->xprt->snd_pipe(cs->conn, pipe)); } +#endif /* The mux operations */ const struct mux_ops mux_pt_ops = {