chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
python: add systemd.id128 module
[elogind.git]
/
src
/
timedate
/
timedated.c
diff --git
a/src/timedate/timedated.c
b/src/timedate/timedated.c
index fdb4335464fd6dbfe1981d86b2b412568498592e..80c24eb62b029f67470ddd3f919f350711d15b44 100644
(file)
--- a/
src/timedate/timedated.c
+++ b/
src/timedate/timedated.c
@@
-35,6
+35,8
@@
#include "hwclock.h"
#include "conf-files.h"
#include "path-util.h"
#include "hwclock.h"
#include "conf-files.h"
#include "path-util.h"
+#include "fileio-label.h"
+#include "label.h"
#define NULL_ADJTIME_UTC "0.0 0 0\n0\nUTC\n"
#define NULL_ADJTIME_LOCAL "0.0 0 0\n0\nLOCAL\n"
#define NULL_ADJTIME_UTC "0.0 0 0\n0\nUTC\n"
#define NULL_ADJTIME_LOCAL "0.0 0 0\n0\nLOCAL\n"
@@
-176,14
+178,6
@@
static int read_data(void) {
}
}
}
}
-#ifdef HAVE_DEBIAN
- r = read_one_line_file("/etc/timezone", &tz.zone);
- if (r < 0) {
- if (r != -ENOENT)
- log_warning("Failed to read /etc/timezone: %s", strerror(-r));
- }
-#endif
-
have_timezone:
if (isempty(tz.zone)) {
free(tz.zone);
have_timezone:
if (isempty(tz.zone)) {
free(tz.zone);
@@
-277,8
+271,8
@@
static int write_data_local_rtc(void) {
return 0;
}
}
return 0;
}
}
-
- r = write_one_line_file_atomic("/etc/adjtime", w);
+ label_init("/etc");
+ r = write_one_line_file_atomic
_label
("/etc/adjtime", w);
free(w);
return r;
free(w);
return r;
@@
-288,7
+282,7
@@
static char** get_ntp_services(void) {
char **r = NULL, **files, **i;
int k;
char **r = NULL, **files, **i;
int k;
- k = conf_files_list(&files, ".list",
+ k = conf_files_list(&files, ".list",
NULL,
"/etc/systemd/ntp-units.d",
"/run/systemd/ntp-units.d",
"/usr/local/lib/systemd/ntp-units.d",
"/etc/systemd/ntp-units.d",
"/run/systemd/ntp-units.d",
"/usr/local/lib/systemd/ntp-units.d",