mirror of
https://github.com/systemd/systemd.git
synced 2026-08-05 07:30:30 +00:00
timesync: return earlier when an empty string is specified
This commit is contained in:
@@ -84,15 +84,16 @@ int config_parse_servers(
|
||||
assert(lvalue);
|
||||
assert(rvalue);
|
||||
|
||||
if (isempty(rvalue))
|
||||
if (isempty(rvalue)) {
|
||||
manager_flush_server_names(m, ltype);
|
||||
else {
|
||||
r = manager_parse_server_string(m, ltype, rvalue);
|
||||
if (r < 0) {
|
||||
log_syntax(unit, LOG_WARNING, filename, line, r,
|
||||
"Failed to parse NTP server string '%s', ignoring: %m", rvalue);
|
||||
return 0;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
r = manager_parse_server_string(m, ltype, rvalue);
|
||||
if (r < 0) {
|
||||
log_syntax(unit, LOG_WARNING, filename, line, r,
|
||||
"Failed to parse NTP server string '%s', ignoring: %m", rvalue);
|
||||
return 0;
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user