]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
CLEANUP: conn-stream: Don't export internal functions
authorChristopher Faulet <cfaulet@haproxy.com>
Tue, 12 Apr 2022 06:49:27 +0000 (08:49 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Wed, 13 Apr 2022 13:10:16 +0000 (15:10 +0200)
cs_new() and cs_attach_app() are only used internally. Thus, there is no
reason to export them.

include/haproxy/conn_stream.h
src/conn_stream.c

index 7cf44ada4abf6b52899bdb780d7617aad836b723..ab2809d248e98f2d187f58db536640452ac10724 100644 (file)
@@ -38,7 +38,6 @@ struct check;
 struct cs_endpoint *cs_endpoint_new();
 void cs_endpoint_free(struct cs_endpoint *endp);
 
-struct conn_stream *cs_new(struct cs_endpoint *endp);
 struct conn_stream *cs_new_from_mux(struct cs_endpoint *endp, struct session *sess, struct buffer *input);
 struct conn_stream *cs_new_from_applet(struct cs_endpoint *endp, struct session *sess, struct buffer *input);
 struct conn_stream *cs_new_from_strm(struct stream *strm, unsigned int flags);
@@ -46,7 +45,6 @@ struct conn_stream *cs_new_from_check(struct check *check, unsigned int flags);
 void cs_free(struct conn_stream *cs);
 
 int cs_attach_mux(struct conn_stream *cs, void *target, void *ctx);
-void cs_attach_applet(struct conn_stream *cs, void *target, void *ctx);
 int cs_attach_strm(struct conn_stream *cs, struct stream *strm);
 
 int cs_reset_endp(struct conn_stream *cs);
index 2747e9756cba8646a7b531fbc8bca5abed94c085..38aaff293bed33ca02823d18647bbefa8a9d5b30 100644 (file)
@@ -109,7 +109,7 @@ void cs_endpoint_free(struct cs_endpoint *endp)
 /* Tries to allocate a new conn_stream and initialize its main fields. On
  * failure, nothing is allocated and NULL is returned.
  */
-struct conn_stream *cs_new(struct cs_endpoint *endp)
+static struct conn_stream *cs_new(struct cs_endpoint *endp)
 {
        struct conn_stream *cs;
 
@@ -251,7 +251,7 @@ int cs_attach_mux(struct conn_stream *cs, void *target, void *ctx)
 }
 
 /* Attaches a conn_stream to an applet endpoint and sets the endpoint ctx */
-void cs_attach_applet(struct conn_stream *cs, void *target, void *ctx)
+static void cs_attach_applet(struct conn_stream *cs, void *target, void *ctx)
 {
        struct appctx *appctx = target;