diff --git a/contrib/mod_defender/defender.h b/contrib/mod_defender/defender.h index 088416e57..59241b22b 100644 --- a/contrib/mod_defender/defender.h +++ b/contrib/mod_defender/defender.h @@ -12,7 +12,7 @@ #ifndef __DEFENDER_H__ #define __DEFENDER_H__ -#include +#include struct defender_request { struct sample clientip; diff --git a/contrib/prometheus-exporter/service-prometheus.c b/contrib/prometheus-exporter/service-prometheus.c index cdced5639..fa36aa7f0 100644 --- a/contrib/prometheus-exporter/service-prometheus.c +++ b/contrib/prometheus-exporter/service-prometheus.c @@ -31,7 +31,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/include/haproxy/auth.h b/include/haproxy/auth.h index 3eafa410e..d7ec2f722 100644 --- a/include/haproxy/auth.h +++ b/include/haproxy/auth.h @@ -17,7 +17,7 @@ #include #include #include -#include +#include extern struct userlist *userlist; diff --git a/include/haproxy/map-t.h b/include/haproxy/map-t.h index 902b064a2..d6085ee6b 100644 --- a/include/haproxy/map-t.h +++ b/include/haproxy/map-t.h @@ -23,7 +23,7 @@ #define _HAPROXY_MAP_T_H #include -#include +#include struct map_descriptor { struct sample_conv *conv; /* original converter descriptor */ diff --git a/include/haproxy/map.h b/include/haproxy/map.h index 140148c33..3ec3418d8 100644 --- a/include/haproxy/map.h +++ b/include/haproxy/map.h @@ -23,7 +23,7 @@ #define _HAPROXY_MAP_H #include -#include +#include /* maps output sample parser */ int map_parse_ip(const char *text, struct sample_data *data); diff --git a/include/haproxy/pattern-t.h b/include/haproxy/pattern-t.h index 7787ec30b..a977527a1 100644 --- a/include/haproxy/pattern-t.h +++ b/include/haproxy/pattern-t.h @@ -29,7 +29,7 @@ #include #include -#include +#include /* Pattern matching function result. diff --git a/include/haproxy/payload.h b/include/haproxy/payload.h index a99adf0ca..da5b4e117 100644 --- a/include/haproxy/payload.h +++ b/include/haproxy/payload.h @@ -23,7 +23,7 @@ #define _HAPROXY_PAYLOAD_H #include -#include +#include #include int fetch_rdp_cookie_name(struct stream *s, struct sample *smp, const char *cname, int clen); diff --git a/include/types/sample.h b/include/haproxy/sample-t.h similarity index 98% rename from include/types/sample.h rename to include/haproxy/sample-t.h index 0bec0c4f9..9403d7bff 100644 --- a/include/types/sample.h +++ b/include/haproxy/sample-t.h @@ -1,5 +1,5 @@ /* - * include/types/sample.h + * include/haproxy/sample-t.h * Macros, variables and structures for sample management. * * Copyright (C) 2009-2010 EXCELIANCE, Emeric Brun @@ -20,18 +20,17 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ -#ifndef _TYPES_SAMPLE_H -#define _TYPES_SAMPLE_H +#ifndef _HAPROXY_SAMPLE_T_H +#define _HAPROXY_SAMPLE_T_H #include #include +#include #include #include #include -struct arg; - /* input and output sample types */ enum { SMP_T_ANY = 0, /* any type */ @@ -179,8 +178,6 @@ enum { SMP_VAL_BE_CHK_RUL, }; -extern const unsigned int fetch_cap[SMP_SRC_ENTRIES]; - /* Sample fetch options are passed to sample fetch functions to add precision * about what is desired : * - fetch direction (req/resp) @@ -213,6 +210,7 @@ enum { /* needed below */ struct session; struct stream; +struct arg; /* a sample context might be used by any sample fetch function in order to * store information needed across multiple calls (eg: restart point for a @@ -326,6 +324,5 @@ struct sample_conv_kw_list { }; typedef int (*sample_cast_fct)(struct sample *smp); -extern sample_cast_fct sample_casts[SMP_TYPES][SMP_TYPES]; -#endif /* _TYPES_SAMPLE_H */ +#endif /* _HAPROXY_SAMPLE_T_H */ diff --git a/include/proto/sample.h b/include/haproxy/sample.h similarity index 94% rename from include/proto/sample.h rename to include/haproxy/sample.h index b4d52c5ea..1c30fd4a4 100644 --- a/include/proto/sample.h +++ b/include/haproxy/sample.h @@ -1,5 +1,5 @@ /* - * include/proto/sample.h + * include/haproxy/sample.h * Functions for samples management. * * Copyright (C) 2009-2010 EXCELIANCE, Emeric Brun @@ -20,12 +20,16 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ -#ifndef _PROTO_SAMPLE_H -#define _PROTO_SAMPLE_H +#ifndef _HAPROXY_SAMPLE_H +#define _HAPROXY_SAMPLE_H -#include +#include +#include +#include #include +extern sample_cast_fct sample_casts[SMP_TYPES][SMP_TYPES]; +extern const unsigned int fetch_cap[SMP_SRC_ENTRIES]; extern const char *smp_to_type[SMP_TYPES]; struct sample_expr *sample_parse_expr(char **str, int *idx, const char *file, int line, char **err, struct arg_list *al, char **endptr); @@ -170,4 +174,4 @@ int smp_make_rw(struct sample *smp) return smp && (smp_is_rw(smp) || smp_dup(smp)); } -#endif /* _PROTO_SAMPLE_H */ +#endif /* _HAPROXY_SAMPLE_H */ diff --git a/include/proto/acl.h b/include/proto/acl.h index 28b49c448..56ae22899 100644 --- a/include/proto/acl.h +++ b/include/proto/acl.h @@ -24,7 +24,6 @@ #include #include -#include /* * FIXME: we need destructor functions too ! diff --git a/include/proto/http_fetch.h b/include/proto/http_fetch.h index e631bc03a..3a7261aa8 100644 --- a/include/proto/http_fetch.h +++ b/include/proto/http_fetch.h @@ -27,7 +27,7 @@ #include #include #include -#include +#include struct htx *smp_prefetch_htx(struct sample *smp, struct channel *chn, struct check *check, int vol); int val_hdr(struct arg *arg, char **err_msg); diff --git a/include/proto/protocol_buffers.h b/include/proto/protocol_buffers.h index 3e1571a30..16ccee577 100644 --- a/include/proto/protocol_buffers.h +++ b/include/proto/protocol_buffers.h @@ -24,8 +24,8 @@ #include #include +#include #include -#include #define PBUF_VARINT_DONT_STOP_BIT 7 #define PBUF_VARINT_DONT_STOP_BITMASK (1 << PBUF_VARINT_DONT_STOP_BIT) diff --git a/include/proto/spoe.h b/include/proto/spoe.h index 584b38af8..d9e909820 100644 --- a/include/proto/spoe.h +++ b/include/proto/spoe.h @@ -23,11 +23,10 @@ #define _PROTO_SPOE_H #include +#include #include -#include - /* Encode a buffer. Its length is encoded as a varint, followed by a copy * of . It must have enough space in <*buf> to encode the buffer, else an diff --git a/include/types/checks.h b/include/types/checks.h index 80f6321f2..9b914d00d 100644 --- a/include/types/checks.h +++ b/include/types/checks.h @@ -24,7 +24,7 @@ #include #include -#include +#include #include #include #include diff --git a/include/types/protocol_buffers.h b/include/types/protocol_buffers.h index 8509b01c4..35e8444cc 100644 --- a/include/types/protocol_buffers.h +++ b/include/types/protocol_buffers.h @@ -68,6 +68,7 @@ struct pbuf_fid { size_t sz; }; +struct sample; struct protobuf_parser_def { int (*skip)(unsigned char **pos, size_t *left, size_t vlen); int (*smp_store)(struct sample *, int type, diff --git a/include/types/proxy.h b/include/types/proxy.h index af33021b1..a72232f6a 100644 --- a/include/types/proxy.h +++ b/include/types/proxy.h @@ -44,7 +44,7 @@ #include #include #include -#include +#include #include #include diff --git a/include/types/spoe.h b/include/types/spoe.h index f08b9adcd..fdaba93ea 100644 --- a/include/types/spoe.h +++ b/include/types/spoe.h @@ -32,7 +32,7 @@ #include #include #include -#include +#include #include #include diff --git a/include/types/stick_table.h b/include/types/stick_table.h index e34504800..0ee7b95f7 100644 --- a/include/types/stick_table.h +++ b/include/types/stick_table.h @@ -33,7 +33,7 @@ #include #include #include -#include +#include /* The types of extra data we can store in a stick table */ enum { diff --git a/include/types/vars.h b/include/types/vars.h index 62b944b25..d8ec71c61 100644 --- a/include/types/vars.h +++ b/include/types/vars.h @@ -4,7 +4,7 @@ #include #include -#include +#include enum vars_scope { SCOPE_SESS = 0, diff --git a/src/51d.c b/src/51d.c index ceff8283e..2309592dd 100644 --- a/src/51d.c +++ b/src/51d.c @@ -12,7 +12,7 @@ #include #include #include -#include +#include #include #include #include <51Degrees.h> diff --git a/src/acl.c b/src/acl.c index 17a5e1041..d2187e8e5 100644 --- a/src/acl.c +++ b/src/acl.c @@ -28,7 +28,7 @@ #include #include #include -#include +#include #include #include diff --git a/src/backend.c b/src/backend.c index 6c6c26d81..e12f207e4 100644 --- a/src/backend.c +++ b/src/backend.c @@ -49,7 +49,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/src/cfgparse-listen.c b/src/cfgparse-listen.c index d2bd8d45b..0e255af56 100644 --- a/src/cfgparse-listen.c +++ b/src/cfgparse-listen.c @@ -19,6 +19,7 @@ #include #include #include +#include #include #include diff --git a/src/cfgparse.c b/src/cfgparse.c index 1dfdbc21c..6c675c4b8 100644 --- a/src/cfgparse.c +++ b/src/cfgparse.c @@ -74,7 +74,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/src/checks.c b/src/checks.c index 2e4c4b0c2..d74296968 100644 --- a/src/checks.c +++ b/src/checks.c @@ -68,7 +68,7 @@ #include #include #include -#include +#include static int tcpcheck_get_step_id(struct check *, struct tcpcheck_rule *); diff --git a/src/cli.c b/src/cli.c index 69f1ec41f..f5f197f97 100644 --- a/src/cli.c +++ b/src/cli.c @@ -34,6 +34,7 @@ #include #include #include +#include #include #include #include @@ -58,7 +59,6 @@ #include #include #include -#include #include #include #include diff --git a/src/connection.c b/src/connection.c index afe881cd9..5652a2588 100644 --- a/src/connection.c +++ b/src/connection.c @@ -23,7 +23,7 @@ #include #include #include -#include +#include #include diff --git a/src/da.c b/src/da.c index 8ff5bfac4..aef12a2fe 100644 --- a/src/da.c +++ b/src/da.c @@ -10,7 +10,7 @@ #include #include #include -#include +#include #include static struct { diff --git a/src/dns.c b/src/dns.c index 32c4efa36..e176b789d 100644 --- a/src/dns.c +++ b/src/dns.c @@ -25,6 +25,7 @@ #include #include #include +#include #include #include #include @@ -40,7 +41,6 @@ #include #include #include -#include #include #include #include diff --git a/src/fcgi-app.c b/src/fcgi-app.c index d9f6bdbe2..6d02e897a 100644 --- a/src/fcgi-app.c +++ b/src/fcgi-app.c @@ -16,6 +16,7 @@ #include #include #include +#include #include #include @@ -26,7 +27,6 @@ #include #include #include -#include #include #include diff --git a/src/flt_http_comp.c b/src/flt_http_comp.c index c081e2790..5ab6a01c7 100644 --- a/src/flt_http_comp.c +++ b/src/flt_http_comp.c @@ -18,15 +18,14 @@ #include #include #include +#include #include #include #include -#include #include #include -#include #include const char *http_comp_flt_id = "compression filter"; diff --git a/src/flt_spoe.c b/src/flt_spoe.c index 9f69f9f2e..010dac2a5 100644 --- a/src/flt_spoe.c +++ b/src/flt_spoe.c @@ -17,6 +17,7 @@ #include #include #include +#include #include #include #include @@ -33,7 +34,6 @@ #include #include #include -#include #include #include #include diff --git a/src/frontend.c b/src/frontend.c index 0be29292d..00c31d84e 100644 --- a/src/frontend.c +++ b/src/frontend.c @@ -25,6 +25,7 @@ #include #include #include +#include #include #include @@ -38,7 +39,6 @@ #include #include #include -#include #include #include #include diff --git a/src/haproxy.c b/src/haproxy.c index 9e6627c57..60c5f65cb 100644 --- a/src/haproxy.c +++ b/src/haproxy.c @@ -98,6 +98,7 @@ #include #include #include +#include #include #include #include diff --git a/src/hlua.c b/src/hlua.c index 69d84bd6b..5b670c741 100644 --- a/src/hlua.c +++ b/src/hlua.c @@ -37,6 +37,7 @@ #include #include #include +#include #include #include @@ -52,7 +53,6 @@ #include #include #include -#include #include #include #include diff --git a/src/http_act.c b/src/http_act.c index f2b803ec3..0549bc018 100644 --- a/src/http_act.c +++ b/src/http_act.c @@ -26,6 +26,7 @@ #include #include #include +#include #include #include #include diff --git a/src/http_conv.c b/src/http_conv.c index da7d53f93..730809a9f 100644 --- a/src/http_conv.c +++ b/src/http_conv.c @@ -20,6 +20,7 @@ #include #include #include +#include #include #include @@ -27,7 +28,6 @@ #include #include -#include #include static int smp_check_http_date_unit(struct arg *args, struct sample_conv *conv, diff --git a/src/http_fetch.c b/src/http_fetch.c index e85978bad..634847aee 100644 --- a/src/http_fetch.c +++ b/src/http_fetch.c @@ -27,6 +27,7 @@ #include #include #include +#include #include #include @@ -38,7 +39,6 @@ #include #include #include -#include #include diff --git a/src/http_htx.c b/src/http_htx.c index 8524d8af5..d018ca5b0 100644 --- a/src/http_htx.c +++ b/src/http_htx.c @@ -16,6 +16,7 @@ #include #include +#include #include #include @@ -26,7 +27,6 @@ #include #include -#include struct buffer http_err_chunks[HTTP_ERR_SIZE]; struct http_reply http_err_replies[HTTP_ERR_SIZE]; diff --git a/src/http_rules.c b/src/http_rules.c index 2ec91d9d5..79c9936ff 100644 --- a/src/http_rules.c +++ b/src/http_rules.c @@ -32,7 +32,7 @@ #include #include #include -#include +#include /* List head of all known action keywords for "http-request" */ diff --git a/src/listener.c b/src/listener.c index 152473e08..3f6230ffb 100644 --- a/src/listener.c +++ b/src/listener.c @@ -36,7 +36,7 @@ #include #include #include -#include +#include #include #include diff --git a/src/log.c b/src/log.c index 7c62f6dfa..2bc0990c3 100644 --- a/src/log.c +++ b/src/log.c @@ -40,7 +40,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/src/map.c b/src/map.c index 0066257d6..33f24dd9f 100644 --- a/src/map.c +++ b/src/map.c @@ -28,7 +28,7 @@ #include #include #include -#include +#include /* Parse an IPv4 or IPv6 address and store it into the sample. * The output type is IPv4 or IPv6. diff --git a/src/pattern.c b/src/pattern.c index e6250b380..93972341a 100644 --- a/src/pattern.c +++ b/src/pattern.c @@ -23,7 +23,7 @@ #include #include -#include +#include #include #include diff --git a/src/payload.c b/src/payload.c index 3d176d663..af4ae1cab 100644 --- a/src/payload.c +++ b/src/payload.c @@ -22,7 +22,7 @@ #include #include #include -#include +#include #include diff --git a/src/proto_tcp.c b/src/proto_tcp.c index 2988007f4..de001c2a5 100644 --- a/src/proto_tcp.c +++ b/src/proto_tcp.c @@ -36,6 +36,7 @@ #include #include #include +#include #include #include @@ -53,7 +54,6 @@ #include #include #include -#include #include #include #include diff --git a/src/queue.c b/src/queue.c index 83863990d..bbf11e22d 100644 --- a/src/queue.c +++ b/src/queue.c @@ -72,13 +72,13 @@ #include #include #include +#include #include #include #include #include #include -#include #include #include #include diff --git a/src/sample.c b/src/sample.c index c13a1ead1..871db000f 100644 --- a/src/sample.c +++ b/src/sample.c @@ -26,6 +26,7 @@ #include #include #include +#include #include #include #include @@ -34,7 +35,6 @@ #include #include #include -#include #include #include #include diff --git a/src/server.c b/src/server.c index 468814c40..ae4f044b7 100644 --- a/src/server.c +++ b/src/server.c @@ -22,6 +22,7 @@ #include #include #include +#include #include #include @@ -37,7 +38,6 @@ #include #include #include -#include #include #include #include diff --git a/src/ssl_sample.c b/src/ssl_sample.c index f27b2e6b5..509b0c575 100644 --- a/src/ssl_sample.c +++ b/src/ssl_sample.c @@ -24,16 +24,15 @@ #include #include #include +#include #include #include -#include #include #include #include #include -#include /***** Below are some sample fetching functions for ACL/patterns *****/ diff --git a/src/stats.c b/src/stats.c index b0ee43428..6e5393402 100644 --- a/src/stats.c +++ b/src/stats.c @@ -60,7 +60,6 @@ #include #include #include -#include #include #include #include diff --git a/src/stick_table.c b/src/stick_table.c index 011a6a314..7026e39ca 100644 --- a/src/stick_table.c +++ b/src/stick_table.c @@ -36,7 +36,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/src/stream.c b/src/stream.c index 8e7697992..b3e71480a 100644 --- a/src/stream.c +++ b/src/stream.c @@ -55,7 +55,6 @@ #include #include #include -#include #include #include #include diff --git a/src/tcp_rules.c b/src/tcp_rules.c index 6cd87efa0..6a878fb7d 100644 --- a/src/tcp_rules.c +++ b/src/tcp_rules.c @@ -14,6 +14,7 @@ #include #include #include +#include #include #include #include @@ -27,7 +28,6 @@ #include #include #include -#include #include #include #include diff --git a/src/vars.c b/src/vars.c index 8cc4c4893..f69dbbbcc 100644 --- a/src/vars.c +++ b/src/vars.c @@ -5,12 +5,12 @@ #include #include #include +#include #include #include #include -#include #include #include #include diff --git a/src/wurfl.c b/src/wurfl.c index 78288bee6..43cedf510 100644 --- a/src/wurfl.c +++ b/src/wurfl.c @@ -12,7 +12,7 @@ #include #include #include -#include +#include #include #include