CLEANUP: assorted typo fixes in the code and comments

This is 15th iteration of typo fixes
This commit is contained in:
Ilya Shipitsin 2021-01-06 21:20:16 +05:00 committed by Willy Tarreau
parent 10d5c3172b
commit b8888ab557
10 changed files with 23 additions and 23 deletions

View File

@ -37,7 +37,7 @@ static inline int port_range_alloc_port(struct port_range *range)
get = _HA_ATOMIC_LOAD(&range->get); get = _HA_ATOMIC_LOAD(&range->get);
do { do {
/* barrier ot make sure get is loaded before put */ /* barrier to make sure get is loaded before put */
__ha_barrier_atomic_load(); __ha_barrier_atomic_load();
put = _HA_ATOMIC_LOAD(&range->put_t); put = _HA_ATOMIC_LOAD(&range->put_t);
if (unlikely(put == get)) if (unlikely(put == get))

View File

@ -49,7 +49,7 @@ __decl_thread(static HA_SPINLOCK_T auth_lock);
#endif #endif
/* find targets for selected groups. The function returns pointer to /* find targets for selected groups. The function returns pointer to
* the userlist struct ot NULL if name is NULL/empty or unresolvable. * the userlist struct or NULL if name is NULL/empty or unresolvable.
*/ */
struct userlist * struct userlist *

View File

@ -713,7 +713,7 @@ cache_store_http_end(struct stream *s, struct filter *filter,
/* /*
* This intends to be used when checking HTTP headers for some * This intends to be used when checking HTTP headers for some
* word=value directive. Return a pointer to the first character of value, if * word=value directive. Return a pointer to the first character of value, if
* the word was not found or if there wasn't any value assigned ot it return NULL * the word was not found or if there wasn't any value assigned or it return NULL
*/ */
char *directive_value(const char *sample, int slen, const char *word, int wlen) char *directive_value(const char *sample, int slen, const char *word, int wlen)
{ {
@ -965,7 +965,7 @@ static void set_secondary_key_encoding(struct htx *htx, char *secondary_key)
resp_encoding_bitmap |= VARY_ENCODING_IDENTITY; resp_encoding_bitmap |= VARY_ENCODING_IDENTITY;
/* Rewrite the bitmap part of the hash with the new bitmap that only /* Rewrite the bitmap part of the hash with the new bitmap that only
* correponds the the response's encoding. */ * corresponds the the response's encoding. */
write_u32(secondary_key + offset, resp_encoding_bitmap); write_u32(secondary_key + offset, resp_encoding_bitmap);
} }
@ -2292,7 +2292,7 @@ static int accept_encoding_normalizer(struct htx *htx, struct ist hdr_name,
unsigned int encoding_value; unsigned int encoding_value;
unsigned int rejected_encoding; unsigned int rejected_encoding;
/* A user agent always accepts an unencoded value unless it explicitely /* A user agent always accepts an unencoded value unless it explicitly
* refuses it through an "identity;q=0" accept-encoding value. */ * refuses it through an "identity;q=0" accept-encoding value. */
hash.encoding_bitmap |= VARY_ENCODING_IDENTITY; hash.encoding_bitmap |= VARY_ENCODING_IDENTITY;
@ -2318,12 +2318,12 @@ static int accept_encoding_normalizer(struct htx *htx, struct ist hdr_name,
} }
/* If a "*" was found in the accepted encodings (without a null weight), /* If a "*" was found in the accepted encodings (without a null weight),
* all the encoding are accepted except the ones explicitely rejected. */ * all the encoding are accepted except the ones explicitly rejected. */
if (hash.encoding_bitmap & VARY_ENCODING_STAR) { if (hash.encoding_bitmap & VARY_ENCODING_STAR) {
hash.encoding_bitmap = ~0; hash.encoding_bitmap = ~0;
} }
/* Clear explicitely rejected encodings from the bitmap */ /* Clear explicitly rejected encodings from the bitmap */
hash.encoding_bitmap &= encoding_bmp_bl; hash.encoding_bitmap &= encoding_bmp_bl;
/* As per RFC7231#5.3.4, "If no Accept-Encoding field is in the request, /* As per RFC7231#5.3.4, "If no Accept-Encoding field is in the request,

View File

@ -132,7 +132,7 @@ static void _do_poll(struct poller *p, int exp, int wake)
break; break;
if (fdtab[fd].update_mask & tid_bit) { if (fdtab[fd].update_mask & tid_bit) {
/* Cheat a bit, as the state is global to all pollers /* Cheat a bit, as the state is global to all pollers
* we don't need every thread ot take care of the * we don't need every thread or take care of the
* update. * update.
*/ */
_HA_ATOMIC_AND(&fdtab[fd].update_mask, ~all_threads_mask); _HA_ATOMIC_AND(&fdtab[fd].update_mask, ~all_threads_mask);

View File

@ -123,7 +123,7 @@ static void _do_poll(struct poller *p, int exp, int wake)
break; break;
if (fdtab[fd].update_mask & tid_bit) { if (fdtab[fd].update_mask & tid_bit) {
/* Cheat a bit, as the state is global to all pollers /* Cheat a bit, as the state is global to all pollers
* we don't need every thread ot take care of the * we don't need every thread or take care of the
* update. * update.
*/ */
_HA_ATOMIC_AND(&fdtab[fd].update_mask, ~all_threads_mask); _HA_ATOMIC_AND(&fdtab[fd].update_mask, ~all_threads_mask);

View File

@ -1706,7 +1706,7 @@ __LJMP static int hlua_map_new(struct lua_State *L)
/* load the map. */ /* load the map. */
if (!sample_load_map(args, &conv, file, line, &err)) { if (!sample_load_map(args, &conv, file, line, &err)) {
/* error case: we cant use luaL_error because we must /* error case: we can't use luaL_error because we must
* free the err variable. * free the err variable.
*/ */
luaL_where(L, 1); luaL_where(L, 1);
@ -1803,11 +1803,11 @@ static void hlua_socket_handler(struct appctx *appctx)
stream_shutdown(si_strm(si), SF_ERR_KILLED); stream_shutdown(si_strm(si), SF_ERR_KILLED);
} }
/* If we cant write, wakeup the pending write signals. */ /* If we can't write, wakeup the pending write signals. */
if (channel_output_closed(si_ic(si))) if (channel_output_closed(si_ic(si)))
notification_wake(&appctx->ctx.hlua_cosocket.wake_on_write); notification_wake(&appctx->ctx.hlua_cosocket.wake_on_write);
/* If we cant read, wakeup the pending read signals. */ /* If we can't read, wakeup the pending read signals. */
if (channel_input_closed(si_oc(si))) if (channel_input_closed(si_oc(si)))
notification_wake(&appctx->ctx.hlua_cosocket.wake_on_read); notification_wake(&appctx->ctx.hlua_cosocket.wake_on_read);
@ -8589,7 +8589,7 @@ int hlua_post_init()
* - only the function_ref[0] set to -1 and all other positive * - only the function_ref[0] set to -1 and all other positive
* This ensure a same reference is not used both in shared * This ensure a same reference is not used both in shared
* lua state and thread dedicated lua state. Note: is the case * lua state and thread dedicated lua state. Note: is the case
* reach, the shared state is prioritary, but the bug will be * reach, the shared state is priority, but the bug will be
* complicated to found for the end user. * complicated to found for the end user.
*/ */
errors = 0; errors = 0;
@ -8609,8 +8609,8 @@ int hlua_post_init()
} }
if ((fcn->function_ref[0] == -1) == (ret < 0)) { if ((fcn->function_ref[0] == -1) == (ret < 0)) {
ha_alert("Lua function '%s' is referenced both ins shared Lua context (throught lua-load) " ha_alert("Lua function '%s' is referenced both ins shared Lua context (through lua-load) "
"and per-thread Lua context (throught lua-load-per-thread). these two context " "and per-thread Lua context (through lua-load-per-thread). these two context "
"exclusive.\n", fcn->name); "exclusive.\n", fcn->name);
errors++; errors++;
} }
@ -8619,7 +8619,7 @@ int hlua_post_init()
if (errors > 0) if (errors > 0)
return 0; return 0;
/* after this point, this global wil no longer used, so set to /* after this point, this global will no longer be used, so set to
* -1 in order to have probably a segfault if someone use it * -1 in order to have probably a segfault if someone use it
*/ */
hlua_state_id = -1; hlua_state_id = -1;

View File

@ -1125,11 +1125,11 @@ static void h1_adjust_case_outgoing_hdr(struct h1s *h1s, struct h1m *h1m, struct
if (eb_is_empty(&hdrs_map.map)) if (eb_is_empty(&hdrs_map.map))
return; return;
/* No conversion fo the request headers */ /* No conversion for the request headers */
if (!(h1m->flags & H1_MF_RESP) && !(h1s->h1c->px->options2 & PR_O2_H1_ADJ_BUGSRV)) if (!(h1m->flags & H1_MF_RESP) && !(h1s->h1c->px->options2 & PR_O2_H1_ADJ_BUGSRV))
return; return;
/* No conversion fo the response headers */ /* No conversion for the response headers */
if ((h1m->flags & H1_MF_RESP) && !(h1s->h1c->px->options2 & PR_O2_H1_ADJ_BUGCLI)) if ((h1m->flags & H1_MF_RESP) && !(h1s->h1c->px->options2 & PR_O2_H1_ADJ_BUGCLI))
return; return;

View File

@ -574,7 +574,7 @@ static int quic_bind_listener(struct listener *listener, char *errmsg, int errle
static void quic_enable_listener(struct listener *l) static void quic_enable_listener(struct listener *l)
{ {
/* FIXME: The following statements are incorrect. This /* FIXME: The following statements are incorrect. This
* is the responsability of the QUIC xprt to stop accepting new * is the responsibility of the QUIC xprt to stop accepting new
* connections. * connections.
*/ */
if (fd_updt) if (fd_updt)
@ -587,7 +587,7 @@ static void quic_enable_listener(struct listener *l)
static void quic_disable_listener(struct listener *l) static void quic_disable_listener(struct listener *l)
{ {
/* FIXME: The following statements are incorrect. This /* FIXME: The following statements are incorrect. This
* is the responsability of the QUIC xprt to start accepting new * is the responsibility of the QUIC xprt to start accepting new
* connections again. * connections again.
*/ */
if (fd_updt) if (fd_updt)