]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
CLEANUP: Fix typos in the spoe subsystem
authorJoseph Herlant <aerostitch@debian.org>
Thu, 15 Nov 2018 21:46:49 +0000 (13:46 -0800)
committerWilly Tarreau <w@1wt.eu>
Sun, 18 Nov 2018 21:26:42 +0000 (22:26 +0100)
Fix typos in the code comments of the spoe subsystem.

include/proto/spoe.h
src/flt_spoe.c

index b6c4ee2cc37c19ace14868e52515275d0debb6f4..e5b3b4b2c30b7407cb77dc9066e5c86d009cbd48 100644 (file)
@@ -61,7 +61,7 @@ spoe_encode_buffer(const char *str, size_t len, char **buf, char *end)
 /* Encode a buffer, possibly partially. It does the same thing than
  * 'spoe_encode_buffer', but if there is not enough space, it does not fail.
  * On success, it returns the number of copied bytes and <*buf> is moved after
- * the encoded value. If an error occured, it returns -1. */
+ * the encoded value. If an error occurred, it returns -1. */
 static inline int
 spoe_encode_frag_buffer(const char *str, size_t len, char **buf, char *end)
 {
@@ -113,7 +113,7 @@ spoe_decode_buffer(char **buf, char *end, char **str, uint64_t *len)
 
 /* Encode a typed data using value in <smp>. On success, it returns the number
  * of copied bytes and <*buf> is moved after the encoded value. If an error
- * occured, it returns -1.
+ * occurred, it returns -1.
  *
  * If the value is too big to be encoded, depending on its type, then encoding
  * failed or the value is partially encoded. Only strings and binaries can be
index 72e1773a5539c64e7ae0803a9bd00db23223042d..5b66e8f900a70b5ec6facad1cc00188654c32182 100644 (file)
@@ -383,7 +383,7 @@ spoe_str_to_vsn(const char *str, size_t len)
 }
 
 /* Encode the HELLO frame sent by HAProxy to an agent. It returns the number of
- * encoded bytes in the frame on success, 0 if an encoding error occured and -1
+ * encoded bytes in the frame on success, 0 if an encoding error occurred and -1
  * if a fatal error occurred. */
 static int
 spoe_prepare_hahello_frame(struct appctx *appctx, char *frame, size_t size)
@@ -2179,14 +2179,14 @@ spoe_encode_message(struct stream *s, struct spoe_context *ctx,
                if (ctx->frag_ctx.curoff != UINT_MAX)
                        goto encode_arg_value;
 
-               /* Encode the arguement name as a string. It can by NULL */
+               /* Encode the argument name as a string. It can by NULL */
                if (spoe_encode_buffer(arg->name, arg->name_len, buf, end) == -1)
                        goto too_big;
 
                ctx->frag_ctx.curoff = 0;
          encode_arg_value:
 
-               /* Fetch the arguement value */
+               /* Fetch the argument value */
                smp = sample_process(s->be, s->sess, s, dir|SMP_OPT_FINAL, arg->expr, NULL);
                ret = spoe_encode_data(smp, &ctx->frag_ctx.curoff, buf, end);
                if (ret == -1 || ctx->frag_ctx.curoff)