#include <haproxy/api.h>
#include <common/cfgparse.h>
-#include <common/buffer.h>
#include <common/htx.h>
#include <haproxy/pool.h>
#include <haproxy/list.h>
#define _COMMON_H1_H
#include <haproxy/api.h>
+#include <haproxy/dynbuf.h>
#include <haproxy/intops.h>
-#include <common/buffer.h>
#include <common/http.h>
#include <common/http-hdr.h>
#include <import/ist.h>
--- /dev/null
+/*
+ * include/haproxy/dynbuf-t.h
+ * Structure definitions for dynamic buffer management.
+ *
+ * Copyright (C) 2000-2020 Willy Tarreau - w@1wt.eu
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, version 2.1
+ * exclusively.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#ifndef _HAPROXY_DYNBUF_T_H
+#define _HAPROXY_DYNBUF_T_H
+
+#include <haproxy/list-t.h>
+
+/* an element of the <buffer_wq> list. It represents an object that need to
+ * acquire a buffer to continue its process. */
+struct buffer_wait {
+ void *target; /* The waiting object that should be woken up */
+ int (*wakeup_cb)(void *); /* The function used to wake up the <target>, passed as argument */
+ struct mt_list list; /* Next element in the <buffer_wq> list */
+};
+
+#endif /* _HAPROXY_DYNBUF_T_H */
+
+/*
+ * Local variables:
+ * c-indent-level: 8
+ * c-basic-offset: 8
+ * End:
+ */
/*
- * include/common/buffer.h
- * Buffer management definitions, macros and inline functions.
+ * include/haproxy/dynbuf.h
+ * Buffer management functions.
*
- * Copyright (C) 2000-2012 Willy Tarreau - w@1wt.eu
+ * Copyright (C) 2000-2020 Willy Tarreau - w@1wt.eu
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef _COMMON_BUFFER_H
-#define _COMMON_BUFFER_H
+#ifndef _HAPROXY_DYNBUF_H
+#define _HAPROXY_DYNBUF_H
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#include <import/ist.h>
+#include <haproxy/activity.h>
#include <haproxy/api.h>
#include <haproxy/buf.h>
#include <haproxy/chunk.h>
-#include <import/ist.h>
-#include <haproxy/istbuf.h>
+#include <haproxy/dynbuf-t.h>
+#include <haproxy/list-t.h>
#include <haproxy/pool.h>
-#include <haproxy/activity.h>
-
-/* an element of the <buffer_wq> list. It represents an object that need to
- * acquire a buffer to continue its process. */
-struct buffer_wait {
- void *target; /* The waiting object that should be woken up */
- int (*wakeup_cb)(void *); /* The function used to wake up the <target>, passed as argument */
- struct mt_list list; /* Next element in the <buffer_wq> list */
-};
-
extern struct pool_head *pool_head_buffer;
extern struct mt_list buffer_wq;
__decl_thread(extern HA_SPINLOCK_T buffer_wq_lock);
}
-#endif /* _COMMON_BUFFER_H */
+#endif /* _HAPROXY_DYNBUF_H */
/*
* Local variables:
#include <haproxy/api.h>
#include <haproxy/chunk.h>
+#include <haproxy/dynbuf.h>
#include <common/htx.h>
#include <common/ticks.h>
#include <haproxy/time.h>
#define _PROTO_SESSION_H
#include <haproxy/api.h>
-#include <common/buffer.h>
#include <haproxy/pool.h>
#include <types/global.h>
#define _PROTO_TRACE_H
#include <haproxy/api.h>
-#include <common/buffer.h>
#include <common/standard.h>
#include <import/ist.h>
#include <haproxy/list.h>
#define _TYPES_APPLET_H
#include <haproxy/api-t.h>
+#include <haproxy/buf.h>
+#include <haproxy/dynbuf-t.h>
#include <haproxy/freq_ctr-t.h>
#include <types/hlua.h>
#include <types/obj_type.h>
#include <types/proxy.h>
#include <types/stream.h>
-#include <common/buffer.h>
-#include <haproxy/chunk.h>
#include <common/xref.h>
struct appctx;
#define _TYPES_CHANNEL_H
#include <haproxy/api-t.h>
-#include <common/buffer.h>
+#include <haproxy/buf-t.h>
/* The CF_* macros designate Channel Flags, which may be ORed in the bit field
* member 'flags' in struct channel. Here we have several types of flags :
#include <zlib.h>
#endif
-#include <common/buffer.h>
+#include <haproxy/buf-t.h>
struct comp {
struct comp_algo *algos;
#define _TYPES_SINK_H
#include <haproxy/api-t.h>
-#include <common/buffer.h>
#include <import/ist.h>
+#include <haproxy/api.h>
/* A sink may be of 4 distinct types :
* - file descriptor (such as stdout)
#include <sys/time.h>
-#include <common/buffer.h>
+#include <haproxy/dynbuf-t.h>
#include <haproxy/list-t.h>
#include <haproxy/thread.h>
#include <types/ssl_ckch.h>
#include <types/ssl_crtlist.h>
-#include <common/buffer.h>
+#include <haproxy/buf-t.h>
#include <haproxy/thread.h>
#include <haproxy/list-t.h>
#include <haproxy/openssl-compat.h>
#include <arpa/inet.h>
#include <haproxy/api-t.h>
+#include <haproxy/dynbuf-t.h>
#include <haproxy/list-t.h>
#include <types/channel.h>
#define _TYPES_TRACE_H
#include <haproxy/api-t.h>
-#include <common/buffer.h>
#include <import/ist.h>
#include <haproxy/list-t.h>
#include <types/sink.h>
#include <haproxy/api.h>
#include <common/cfgparse.h>
#include <haproxy/chunk.h>
-#include <common/buffer.h>
+#include <haproxy/buf-t.h>
#include <haproxy/errors.h>
#include <haproxy/thread.h>
#include <types/global.h>
#include <sys/types.h>
#include <haproxy/api.h>
-#include <common/buffer.h>
#include <haproxy/hash.h>
#include <common/htx.h>
#include <common/ticks.h>
#include <string.h>
#include <haproxy/api.h>
-#include <common/buffer.h>
+#include <haproxy/dynbuf.h>
+#include <haproxy/list.h>
#include <haproxy/pool.h>
#include <types/global.h>
#include <string.h>
#include <haproxy/api.h>
-#include <common/buffer.h>
+#include <haproxy/buf.h>
#include <proto/channel.h>
#include <haproxy/api.h>
#include <common/cfgparse.h>
#include <haproxy/chunk.h>
+#include <haproxy/istbuf.h>
#include <haproxy/list.h>
#include <common/standard.h>
#include <haproxy/time.h>
#endif /* USE_ZLIB */
#include <haproxy/api.h>
+#include <haproxy/dynbuf.h>
#include <common/cfgparse.h>
#include <haproxy/thread.h>
#include <haproxy/pool.h>
*/
#include <haproxy/api.h>
-#include <common/buffer.h>
+#include <haproxy/buf-t.h>
#include <common/cfgparse.h>
#include <haproxy/errors.h>
#include <common/htx.h>
*/
#include <haproxy/api.h>
-#include <common/buffer.h>
+#include <haproxy/dynbuf.h>
#include <common/cfgparse.h>
#include <common/htx.h>
#include <haproxy/list.h>
#include <haproxy/base64.h>
#include <common/cfgparse.h>
#include <haproxy/chunk.h>
+#include <haproxy/dynbuf.h>
#include <haproxy/errors.h>
#include <haproxy/pool.h>
#include <haproxy/list.h>
*
*/
#include <haproxy/api.h>
+#include <haproxy/istbuf.h>
#include <common/cfgparse.h>
#include <common/h1.h>
#include <common/h2.h>
*/
#include <haproxy/api.h>
+#include <haproxy/istbuf.h>
#include <common/cfgparse.h>
#include <common/h1.h>
#include <common/h2.h>
#include <netinet/tcp.h>
#include <haproxy/api.h>
-#include <common/buffer.h>
+#include <haproxy/buf.h>
#include <common/standard.h>
#include <common/ticks.h>
#include <haproxy/time.h>
*/
#include <haproxy/api.h>
-#include <common/buffer.h>
#include <common/http.h>
#include <haproxy/pool.h>
#include <unistd.h>
#include <haproxy/api.h>
-#include <common/buffer.h>
+#include <haproxy/buf-t.h>
#include <haproxy/openssl-compat.h>
#include <common/standard.h>
#include <import/lru.h>
#include <import/xxhash.h>
-#include <common/buffer.h>
+#include <haproxy/dynbuf.h>
#include <haproxy/chunk.h>
#include <haproxy/errors.h>
#include <haproxy/openssl-compat.h>
*/
-#include <common/buffer.h>
+#include <haproxy/api.h>
+#include <haproxy/buf-t.h>
#include <haproxy/openssl-compat.h>
#include <proto/ssl_sock.h>
#include <haproxy/api.h>
#include <common/cfgparse.h>
-#include <common/buffer.h>
+#include <haproxy/dynbuf.h>
+#include <haproxy/istbuf.h>
#include <haproxy/thread.h>
#include <common/htx.h>
#include <haproxy/pool.h>
#include <sys/types.h>
#include <haproxy/api.h>
-#include <common/buffer.h>
+#include <haproxy/dynbuf.h>
#include <common/standard.h>
#include <common/ticks.h>
#include <haproxy/time.h>
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#include <haproxy/api.h>
-#include <common/buffer.h>
#include <import/ist.h>
+#include <haproxy/api.h>
+#include <haproxy/buf.h>
+#include <haproxy/istbuf.h>
#include <haproxy/list.h>
#include <proto/cli.h>
#include <proto/log.h>
#include <stdarg.h>
#include <haproxy/api.h>
+#include <haproxy/buf-t.h>
#include <common/cfgparse.h>
#include <haproxy/chunk.h>
-#include <common/buffer.h>
#include <haproxy/errors.h>
#include <types/global.h>
#include <proto/arg.h>