Commit 6afe8bfd authored by Daniel Salzman's avatar Daniel Salzman

log: remove useless return value for reconfigure function

parent 9b098d2d
......@@ -474,16 +474,13 @@ static logtype_t get_logtype(const char *logname)
}
}
int log_reconfigure(conf_t *conf, void *data)
void log_reconfigure(conf_t *conf)
{
// Data not used
UNUSED(data);
// Use defaults if no 'log' section is configured.
if (conf_id_count(conf, C_LOG) == 0) {
log_close();
log_init();
return KNOT_EOK;
return;
}
// Find maximum log facility id
......@@ -499,7 +496,7 @@ int log_reconfigure(conf_t *conf, void *data)
// Initialize logsystem
struct log_sink *log = sink_setup(files);
if (log == NULL) {
return KNOT_ENOMEM;
return;
}
// Setup logs
......@@ -539,6 +536,4 @@ int log_reconfigure(conf_t *conf, void *data)
}
sink_publish(log);
return KNOT_EOK;
}
......@@ -199,11 +199,7 @@ int log_update_privileges(int uid, int gid);
* \brief Setup logging facilities from config.
*
* \see syslog.h
*
* \retval KNOT_EOK on success.
* \retval KNOT_EINVAL on invalid parameters.
* \retval KNOT_ENOMEM out of memory error.
*/
int log_reconfigure(conf_t *conf, void *data);
void log_reconfigure(conf_t *conf);
/*! @} */
......@@ -511,7 +511,7 @@ int server_reload(server_t *server, const char *cf)
/* Update to the new config. */
conf_update(new_conf);
log_reconfigure(conf(), NULL);
log_reconfigure(conf());
server_reconfigure(conf(), server);
server_update_zones(conf(), server);
......
......@@ -441,7 +441,7 @@ int main(int argc, char **argv)
}
/* Reconfigure logging. */
log_reconfigure(conf(), NULL);
log_reconfigure(conf());
/* Initialize server. */
server_t server;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment