@cryptotaxi247 / netdata-1 / commits / 815b6fb2a

prevent warnings when compiling against musl

Costa Tsaousis (ktsaou) committed Sep 27, 2016 at 01:04 UTC 815b6fb2a8bdd3a267e3b79c137989b6202b087e
1 file changed +6 -6
src/log.c
+6 -6
@@ -90,22 +90,22 @@ int open_log_file(int fd, FILE **fp, const char *filename, int *enabled_syslog)
90
91 void reopen_all_log_files() {
92 if(stdout_filename)
93 - open_log_file(STDOUT_FILENO, &stdout, stdout_filename, &output_log_syslog);
93 + open_log_file(STDOUT_FILENO, (FILE **)&stdout, stdout_filename, &output_log_syslog);
94
95 if(stderr_filename)
96 - open_log_file(STDERR_FILENO, &stderr, stderr_filename, &error_log_syslog);
96 + open_log_file(STDERR_FILENO, (FILE **)&stderr, stderr_filename, &error_log_syslog);
97
98 if(stdaccess_filename)
99 - stdaccess_fd = open_log_file(stdaccess_fd, &stdaccess, stdaccess_filename, &access_log_syslog);
99 + stdaccess_fd = open_log_file(stdaccess_fd, (FILE **)&stdaccess, stdaccess_filename, &access_log_syslog);
100 }
101
102 void open_all_log_files() {
103 // disable stdin
104 open_log_file(STDIN_FILENO, &stdin, "/dev/null", NULL);
105
106 - open_log_file(STDOUT_FILENO, &stdout, stdout_filename, &output_log_syslog);
107 - open_log_file(STDERR_FILENO, &stderr, stderr_filename, &error_log_syslog);
108 - stdaccess_fd = open_log_file(stdaccess_fd, &stdaccess, stdaccess_filename, &access_log_syslog);
106 + open_log_file(STDOUT_FILENO, (FILE **)&stdout, stdout_filename, &output_log_syslog);
107 + open_log_file(STDERR_FILENO, (FILE **)&stderr, stderr_filename, &error_log_syslog);
108 + stdaccess_fd = open_log_file(stdaccess_fd, (FILE **)&stdaccess, stdaccess_filename, &access_log_syslog);
109 }
110
111 // ----------------------------------------------------------------------------