[systemd-commits] 3 commits - TODO make-man-index.py src/journal
Lennart Poettering
lennart at kemper.freedesktop.org
Mon Jul 16 12:43:23 PDT 2012
TODO | 2 --
make-man-index.py | 2 +-
src/journal/journal-file.c | 20 ++++++--------------
3 files changed, 7 insertions(+), 17 deletions(-)
New commits:
commit 162566a4a12c35e1e86e35ced1748354f7ec935e
Author: Lennart Poettering <lennart at poettering.net>
Date: Mon Jul 16 19:28:05 2012 +0200
journal: use tail/head timestamps from header for cutoff logic
We have them, they are faster to use them, so use them...
diff --git a/src/journal/journal-file.c b/src/journal/journal-file.c
index cd5ab26..a110a00 100644
--- a/src/journal/journal-file.c
+++ b/src/journal/journal-file.c
@@ -2446,26 +2446,21 @@ void journal_default_metrics(JournalMetrics *m, int fd) {
}
int journal_file_get_cutoff_realtime_usec(JournalFile *f, usec_t *from, usec_t *to) {
- Object *o;
- int r;
-
assert(f);
assert(from || to);
if (from) {
- r = journal_file_next_entry(f, NULL, 0, DIRECTION_DOWN, &o, NULL);
- if (r <= 0)
- return r;
+ if (f->header->head_entry_realtime == 0)
+ return -ENOENT;
- *from = le64toh(o->entry.realtime);
+ *from = le64toh(f->header->head_entry_realtime);
}
if (to) {
- r = journal_file_next_entry(f, NULL, 0, DIRECTION_UP, &o, NULL);
- if (r <= 0)
- return r;
+ if (f->header->tail_entry_realtime == 0)
+ return -ENOENT;
- *to = le64toh(o->entry.realtime);
+ *to = le64toh(f->header->tail_entry_realtime);
}
return 1;
commit 74d29da52409ab149738ea76824679d29598e0ac
Author: Lennart Poettering <lennart at poettering.net>
Date: Mon Jul 16 19:26:54 2012 +0200
journald: don't enforce monotonicity of realtime clocks when copying entries
After all the point of the realtime clock (in contrast to the monotonic
clock) is that it does not have to be strictly monotonic, hence don't
enforce this when flushing the journal from /run to /var.
diff --git a/src/journal/journal-file.c b/src/journal/journal-file.c
index 0aada9c..cd5ab26 100644
--- a/src/journal/journal-file.c
+++ b/src/journal/journal-file.c
@@ -2312,9 +2312,6 @@ int journal_file_copy_entry(JournalFile *from, JournalFile *to, Object *o, uint6
ts.monotonic < le64toh(to->header->tail_entry_monotonic))
return -EINVAL;
- if (ts.realtime < le64toh(to->header->tail_entry_realtime))
- return -EINVAL;
-
n = journal_file_entry_n_items(o);
items = alloca(sizeof(EntryItem) * n);
commit a6c9b1c492378a093fe7db69c42a19b8f8193814
Author: Lennart Poettering <lennart at poettering.net>
Date: Mon Jul 16 19:26:08 2012 +0200
man: actually generate h2 headers for letters in index as we meant to
diff --git a/TODO b/TODO
index ae9fbc2..0a923ce 100644
--- a/TODO
+++ b/TODO
@@ -64,8 +64,6 @@ Features:
* journald: we currently rotate only after MaxUse+MaxFilesize has been reached.
-* reexec journald across initrd transition
-
* nspawn: bind mount /var/log/journal from the host
* Document:
diff --git a/make-man-index.py b/make-man-index.py
index 44d15f8..29e3578 100755
--- a/make-man-index.py
+++ b/make-man-index.py
@@ -36,7 +36,7 @@ for n in sorted(index.keys(), key = str.lower):
if letter is None or n[0].upper() != letter:
letter = n[0].upper()
- h2 = SubElement(body, 'h1')
+ h2 = SubElement(body, 'h2')
h2.text = letter
ul = SubElement(body, 'ul')
More information about the systemd-commits
mailing list