From: Christopher Faulet Date: Thu, 5 Jun 2025 13:43:53 +0000 (+0200) Subject: CLEANUP: applet: Simplify a bit comments for applet_put* functions X-Git-Tag: v3.3-dev1~4 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=18f9c71041bf4c57f773d5ab86657cbbd78b1069;p=thirdparty%2Fhaproxy.git CLEANUP: applet: Simplify a bit comments for applet_put* functions Instead of repeating which buffer is used depending on the API used by the applet, a reference to applet_get_outbuf() was added. --- diff --git a/include/haproxy/applet.h b/include/haproxy/applet.h index 74437401d..e9357e773 100644 --- a/include/haproxy/applet.h +++ b/include/haproxy/applet.h @@ -404,8 +404,7 @@ static inline int _applet_putchk(struct appctx *appctx, struct buffer *chunk, return ret; } -/* writes chunk into the applet's output buffer if it uses its own - * bufferx or into the input channel of the stream attached to this applet. +/* writes chunk into the applet output buffer (see applet_get_outbuf). * * Returns the number of written bytes on success or -1 on error (lake of space, * shutdown, invalid call...) @@ -421,8 +420,7 @@ static inline int applet_putchk_stress(struct appctx *appctx, struct buffer *chu return _applet_putchk(appctx, chunk, 1); } -/* writes chars from into the applet's output buffer if it uses its own - * bufferx or into the input channel of the stream attached to this applet. +/* writes chars from into the applet output buffer (see applet_get_outbuf). * * Returns the number of written bytes on success or -1 on error (lake of space, * shutdown, invalid call...) @@ -457,9 +455,8 @@ static inline int applet_putblk(struct appctx *appctx, const char *blk, int len) return ret; } -/* writes chars from up to the trailing zero (excluded) into the applet's - * output buffer if it uses its own bufferx or into the input channel of the - * stream attached to this applet. +/* writes chars from up to the trailing zero (excluded) into the applet + * output buffer (see applet_get_outbuf). * * Returns the number of written bytes on success or -1 on error (lake of space, * shutdown, invalid call...) @@ -495,8 +492,7 @@ static inline int applet_putstr(struct appctx *appctx, const char *str) return ret; } -/* writes character into the applet's output buffer if it uses its own - * bufferx or into the input channel of the stream attached to this applet. +/* writes character into the applet's output buffer (see applet_get_outbuf). * * Returns the number of written bytes on success or -1 on error (lake of space, * shutdown, invalid call...)