@cryptotaxi247 / netdata-1 / commits / 93631017d

Missing extern (#7877)

* missing_extern: Fix missing Fix few externs that were missing in global variables * missing_extern: Variables This commit declares the variables inside .c files

thiagoftsm committed Jan 28, 2020 at 15:27 UTC 93631017d868d8d432124e18c96bbe6dcba4bce0
8 files changed +10 -5
daemon/common.c
+1 -1
@@ -13,4 +13,4 @@ char *netdata_configured_varlib_dir = VARLIB_DIR;
13 char *netdata_configured_home_dir = CACHE_DIR;
14 char *netdata_configured_host_prefix = NULL;
15 char *netdata_configured_timezone = NULL;
16 -
16 +int netdata_ready;
daemon/common.h
+1 -1
@@ -84,6 +84,6 @@ extern char *netdata_configured_timezone;
84 extern int netdata_zero_metrics_enabled;
85 extern int netdata_anonymous_statistics_enabled;
86
87 -int netdata_ready;
87 +extern int netdata_ready;
88
89 #endif /* NETDATA_COMMON_H */
health/health.c
+1
@@ -9,6 +9,7 @@ struct health_cmdapi_thread_status {
9 };
10
11 unsigned int default_health_enabled = 1;
12 +char *silencers_filename;
13
14 // ----------------------------------------------------------------------------
15 // health initialization
health/health.h
+1 -1
@@ -52,7 +52,7 @@ extern unsigned int default_health_enabled;
52
53 #define HEALTH_SILENCERS_MAX_FILE_LEN 10000
54
55 -char *silencers_filename;
55 +extern char *silencers_filename;
56
57 extern void health_init(void);
58 extern void *health_main(void *ptr);
libnetdata/health/health.c
+2
@@ -1,5 +1,7 @@
1 #include "health.h"
2
3 +SILENCERS *silencers;
4 +
5 /**
6 * Create Silencer
7 *
libnetdata/health/health.h
+1 -1
@@ -44,7 +44,7 @@ typedef struct silencers {
44 SILENCER *silencers;
45 } SILENCERS;
46
47 -SILENCERS *silencers;
47 +extern SILENCERS *silencers;
48
49 extern SILENCER *create_silencer(void);
50 extern int health_silencers_json_read_callback(JSON_ENTRY *e);
web/api/web_api_v1.c
+2
@@ -2,6 +2,8 @@
2
3 #include "web_api_v1.h"
4
5 +char *api_secret;
6 +
7 static struct {
8 const char *name;
9 uint32_t hash;
web/api/web_api_v1.h
+1 -1
@@ -29,6 +29,6 @@ extern void host_labels2json(RRDHOST *host, BUFFER *wb, size_t indentation);
29 extern void web_client_api_v1_init(void);
30 extern void web_client_api_v1_management_init(void);
31
32 -char *api_secret;
32 +extern char *api_secret;
33
34 #endif //NETDATA_WEB_API_V1_H