1
0
mirror of https://github.com/netdata/netdata.git synced 2021-06-06 23:03:21 +03:00

Spelling daemon (#10913)

This commit is contained in:
Josh Soref
2021-04-14 05:31:40 -04:00
committed by GitHub
parent 73c403588d
commit 963ed4a178
4 changed files with 9 additions and 9 deletions

View File

@@ -77,7 +77,7 @@
// netdata agent spawn server
#include "spawn/spawn.h"
// the netdata deamon
// the netdata daemon
#include "daemon.h"
#include "main.h"
#include "signals.h"

View File

@@ -921,7 +921,7 @@ int main(int argc, char **argv) {
// set the name for logging
program_name = "netdata";
// parse depercated options
// parse deprecated options
// TODO: Remove this block with the next major release.
{
i = 1;
@@ -1107,21 +1107,21 @@ int main(int argc, char **argv) {
return 1;
}
const char *heystack = argv[optind];
const char *haystack = argv[optind];
const char *needle = argv[optind + 1];
size_t len = strlen(needle) + 1;
char wildcarded[len];
SIMPLE_PATTERN *p = simple_pattern_create(heystack, NULL, SIMPLE_PATTERN_EXACT);
SIMPLE_PATTERN *p = simple_pattern_create(haystack, NULL, SIMPLE_PATTERN_EXACT);
int ret = simple_pattern_matches_extract(p, needle, wildcarded, len);
simple_pattern_free(p);
if(ret) {
fprintf(stdout, "RESULT: MATCHED - pattern '%s' matches '%s', wildcarded '%s'\n", heystack, needle, wildcarded);
fprintf(stdout, "RESULT: MATCHED - pattern '%s' matches '%s', wildcarded '%s'\n", haystack, needle, wildcarded);
return 0;
}
else {
fprintf(stdout, "RESULT: NOT MATCHED - pattern '%s' does not match '%s', wildcarded '%s'\n", heystack, needle, wildcarded);
fprintf(stdout, "RESULT: NOT MATCHED - pattern '%s' does not match '%s', wildcarded '%s'\n", haystack, needle, wildcarded);
return 1;
}
}
@@ -1438,7 +1438,7 @@ int main(int argc, char **argv) {
netdata_threads_init_after_fork((size_t)config_get_number(CONFIG_SECTION_GLOBAL, "pthread stack size", (long)default_stacksize));
// initialyze internal registry
// initialize internal registry
registry_init();
// fork the spawn server
spawn_init();

View File

@@ -44,7 +44,7 @@ static void signal_handler(int signo) {
if(signals_waiting[i].action == NETDATA_SIGNAL_FATAL) {
char buffer[200 + 1];
snprintfz(buffer, 200, "\nSIGNAL HANLDER: received: %s. Oops! This is bad!\n", signals_waiting[i].name);
snprintfz(buffer, 200, "\nSIGNAL HANDLER: received: %s. Oops! This is bad!\n", signals_waiting[i].name);
if(write(STDERR_FILENO, buffer, strlen(buffer)) == -1) {
// nothing to do - we cannot write but there is no way to complain about it
;

View File

@@ -1515,7 +1515,7 @@ static RRDHOST *dbengine_rrdhost_find_or_create(char *name)
);
}
// costants for test_dbengine
// constants for test_dbengine
static const int CHARTS = 64;
static const int DIMS = 16; // That gives us 64 * 16 = 1024 metrics
#define REGIONS (3) // 3 regions of update_every