From faef38c806515e3e314430a6093d8c11c1bd0691 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Wed, 14 Apr 2021 05:27:54 -0400 Subject: Spelling libnetdata (#10917) --- libnetdata/clocks/clocks.h | 4 ++-- libnetdata/config/appconfig.c | 2 +- libnetdata/config/appconfig.h | 2 +- libnetdata/health/health.c | 2 +- libnetdata/json/json.c | 6 +++--- libnetdata/procfile/procfile.c | 6 +++--- libnetdata/procfile/procfile.h | 2 +- libnetdata/socket/security.c | 4 ++-- libnetdata/storage_number/storage_number.h | 2 +- libnetdata/storage_number/tests/test_storage_number.c | 4 ++-- libnetdata/url/url.c | 4 ++-- 11 files changed, 19 insertions(+), 19 deletions(-) diff --git a/libnetdata/clocks/clocks.h b/libnetdata/clocks/clocks.h index cfe99f5e7b..d3475df6af 100644 --- a/libnetdata/clocks/clocks.h +++ b/libnetdata/clocks/clocks.h @@ -112,8 +112,8 @@ extern int clock_gettime(clockid_t clk_id, struct timespec *ts); * All now_*_timeval() functions fill the `struct timeval` with the time from the appropriate clock. * Those functions return 0 on success, -1 else with errno set appropriately. * - * All now_*_sec() functions return the time in seconds from the approriate clock, or 0 on error. - * All now_*_usec() functions return the time in microseconds from the approriate clock, or 0 on error. + * All now_*_sec() functions return the time in seconds from the appropriate clock, or 0 on error. + * All now_*_usec() functions return the time in microseconds from the appropriate clock, or 0 on error. * * Most functions will attempt to use CLOCK_MONOTONIC_COARSE if available to reduce contention overhead and improve * performance scaling. If high precision is required please use one of the available now_*_high_precision_* functions. diff --git a/libnetdata/config/appconfig.c b/libnetdata/config/appconfig.c index f570f32d7c..6e4df2d099 100644 --- a/libnetdata/config/appconfig.c +++ b/libnetdata/config/appconfig.c @@ -302,7 +302,7 @@ int appconfig_move(struct config *root, const char *section_old, const char *nam if(cv_new) goto cleanup; if(unlikely(appconfig_option_index_del(co_old, cv_old) != cv_old)) - error("INTERNAL ERROR: deletion of config '%s' from section '%s', deleted tge wrong config entry.", cv_old->name, co_old->name); + error("INTERNAL ERROR: deletion of config '%s' from section '%s', deleted the wrong config entry.", cv_old->name, co_old->name); if(co_old->values == cv_old) { co_old->values = cv_old->next; diff --git a/libnetdata/config/appconfig.h b/libnetdata/config/appconfig.h index f405eeb09b..246d1d5b92 100644 --- a/libnetdata/config/appconfig.h +++ b/libnetdata/config/appconfig.h @@ -131,7 +131,7 @@ struct section { char *name; - struct section *next; // gloabl config_mutex protects just this + struct section *next; // global config_mutex protects just this struct config_option *values; avl_tree_lock values_index; diff --git a/libnetdata/health/health.c b/libnetdata/health/health.c index 74f7a02663..c44ba08289 100644 --- a/libnetdata/health/health.c +++ b/libnetdata/health/health.c @@ -19,7 +19,7 @@ SILENCER *create_silencer(void) { /** * Health Silencers add * - * Add more one silencer to the list of silenecers. + * Add more one silencer to the list of silencers. * * @param silencer */ diff --git a/libnetdata/json/json.c b/libnetdata/json/json.c index bd164aeffc..1f391eeaae 100644 --- a/libnetdata/json/json.c +++ b/libnetdata/json/json.c @@ -82,7 +82,7 @@ jsmntok_t *json_tokenise(char *js, size_t len, size_t *count) /** * Callback Print * - * Set callback print case necesary and wrinte an information inside a buffer to write in the log. + * Set callback print case necessary and wrinte an information inside a buffer to write in the log. * * @param e a pointer for a structure that has the complete information about json structure. * @@ -518,8 +518,8 @@ size_t json_walk_tree(char *js, jsmntok_t *t, void *callback_data, int (*callbac * @param callback_data additional data to be used together the callback function * @param callback_function function used to create a silencer. * - * @return JSON_OK case everything happend as expected, JSON_CANNOT_PARSE case there were errors in the - * parsing procces and JSON_CANNOT_DOWNLOAD case the string given(js) is NULL. + * @return JSON_OK case everything happened as expected, JSON_CANNOT_PARSE case there were errors in the + * parsing process and JSON_CANNOT_DOWNLOAD case the string given(js) is NULL. */ int json_parse(char *js, void *callback_data, int (*callback_function)(JSON_ENTRY *)) { diff --git a/libnetdata/procfile/procfile.c b/libnetdata/procfile/procfile.c index 4a812baab4..9867c19f63 100644 --- a/libnetdata/procfile/procfile.c +++ b/libnetdata/procfile/procfile.c @@ -312,9 +312,9 @@ procfile *procfile_readall(procfile *ff) { NOINLINE static void procfile_set_separators(procfile *ff, const char *separators) { static PF_CHAR_TYPE def[256]; - static char initilized = 0; + static char initialized = 0; - if(unlikely(!initilized)) { + if(unlikely(!initialized)) { // this is thread safe // if initialized is zero, multiple threads may be executing // this code at the same time, setting in def[] the exact same values @@ -330,7 +330,7 @@ static void procfile_set_separators(procfile *ff, const char *separators) { def[i] = PF_CHAR_IS_WORD; } - initilized = 1; + initialized = 1; } // copy the default diff --git a/libnetdata/procfile/procfile.h b/libnetdata/procfile/procfile.h index b107358abd..d29adf8e6a 100644 --- a/libnetdata/procfile/procfile.h +++ b/libnetdata/procfile/procfile.h @@ -50,7 +50,7 @@ typedef struct { char filename[FILENAME_MAX + 1]; // not populated until profile_filename() is called uint32_t flags; - int fd; // the file desriptor + int fd; // the file descriptor size_t len; // the bytes we have placed into data size_t size; // the bytes we have allocated for data pflines *lines; diff --git a/libnetdata/socket/security.c b/libnetdata/socket/security.c index 53366c4d8f..63a71bcbde 100644 --- a/libnetdata/socket/security.c +++ b/libnetdata/socket/security.c @@ -201,7 +201,7 @@ static SSL_CTX * security_initialize_openssl_server() { * @param selector informs the context that must be initialized, the following list has the valid values: * NETDATA_SSL_CONTEXT_SERVER - the server context * NETDATA_SSL_CONTEXT_STREAMING - Starts the streaming context. - * NETDATA_SSL_CONTEXT_EXPORTING - Starts the OpenTSDB contextv + * NETDATA_SSL_CONTEXT_EXPORTING - Starts the OpenTSDB context */ void security_start_ssl(int selector) { switch (selector) { @@ -218,7 +218,7 @@ void security_start_ssl(int selector) { case NETDATA_SSL_CONTEXT_STREAMING: { netdata_client_ctx = security_initialize_openssl_client(); //This is necessary for the stream, because it is working sometimes with nonblock socket. - //It returns the bitmask afte to change, there is not any description of errors in the documentation + //It returns the bitmask after to change, there is not any description of errors in the documentation SSL_CTX_set_mode(netdata_client_ctx, SSL_MODE_ENABLE_PARTIAL_WRITE |SSL_MODE_ACCEPT_MOVING_WRITE_BUFFER |SSL_MODE_AUTO_RETRY); break; } diff --git a/libnetdata/storage_number/storage_number.h b/libnetdata/storage_number/storage_number.h index 28b7f267c0..4ad7ff6246 100644 --- a/libnetdata/storage_number/storage_number.h +++ b/libnetdata/storage_number/storage_number.h @@ -62,7 +62,7 @@ typedef uint32_t storage_number; #define SN_EXISTS (1 << 24) // the value exists #define SN_EXISTS_RESET (1 << 25) // the value has been overflown -#define SN_EXISTS_100 (1 << 26) // very large value (multipler is 100 instead of 10) +#define SN_EXISTS_100 (1 << 26) // very large value (multiplier is 100 instead of 10) // extract the flags #define get_storage_number_flags(value) ((((storage_number)(value)) & (1 << 24)) | (((storage_number)(value)) & (1 << 25)) | (((storage_number)(value)) & (1 << 26))) diff --git a/libnetdata/storage_number/tests/test_storage_number.c b/libnetdata/storage_number/tests/test_storage_number.c index 0e1320877e..7ef18b1de9 100644 --- a/libnetdata/storage_number/tests/test_storage_number.c +++ b/libnetdata/storage_number/tests/test_storage_number.c @@ -5,7 +5,7 @@ #include #include -static void test_number_pinting(void **state) +static void test_number_printing(void **state) { (void)state; @@ -45,7 +45,7 @@ static void test_number_pinting(void **state) int main(void) { const struct CMUnitTest tests[] = { - cmocka_unit_test(test_number_pinting) + cmocka_unit_test(test_number_printing) }; return cmocka_run_group_tests_name("storage_number", tests, NULL, NULL); diff --git a/libnetdata/url/url.c b/libnetdata/url/url.c index 3de94fde7e..f90b3d5897 100644 --- a/libnetdata/url/url.c +++ b/libnetdata/url/url.c @@ -68,7 +68,7 @@ char url_percent_escape_decode(char *s) { * * @param c is the utf8 character * * - * @return It reurns the length of the specific character. + * @return It returns the length of the specific character. */ char url_utf8_get_byte_length(char c) { if(!IS_UTF8_BYTE(c)) @@ -226,7 +226,7 @@ char *url_decode_r(char *to, char *url, size_t size) { *d = '\0'; - if(unlikely( utf8_check((unsigned char *)to) )) //NULL means sucess here + if(unlikely( utf8_check((unsigned char *)to) )) //NULL means success here return NULL; return to; -- cgit v1.2.3