Re: [systemd-devel] odd seek_tail behaviour

2014-10-24 Thread Sascha Kattelmann
metrical: Same goes for "previous" after "seek_head". You need to do a "next" immediately after "seek_head". I hope that will help, Sascha - Original Message - From: "Daurnimator" To: "systemd Mailing List" Sent: Monday, October 13,

Re: [systemd-devel] odd seek_tail behaviour

2014-10-14 Thread Christian Hesse
Christian Hesse on Mon, 2014/10/13 23:56: > Christian Hesse on Mon, 2014/10/13 20:22: > > Daurnimator on Mon, 2014/10/13 01:27: > > > Hi All, > > > > > > I was trying to write a program that tailed the journal, but found that > > > sd_journal_seek_tail() didn't work as expected. > > > That is:

Re: [systemd-devel] odd seek_tail behaviour

2014-10-13 Thread Christian Hesse
Christian Hesse on Mon, 2014/10/13 20:22: > Daurnimator on Mon, 2014/10/13 01:27: > > Hi All, > > > > I was trying to write a program that tailed the journal, but found that > > sd_journal_seek_tail() didn't work as expected. > > That is: that it would seek to the last/most recent thing in the j

Re: [systemd-devel] odd seek_tail behaviour

2014-10-13 Thread Christian Hesse
Daurnimator on Mon, 2014/10/13 01:27: > Hi All, > > I was trying to write a program that tailed the journal, but found that > sd_journal_seek_tail() didn't work as expected. > That is: that it would seek to the last/most recent thing in the journal, > and I could tail things from there. > > I wh

Re: [systemd-devel] odd seek_tail behaviour

2014-10-13 Thread Daurnimator
On 13 October 2014 07:22, Sascha Kattelmann wrote: > here is a related "bug" report: > https://bugs.freedesktop.org/show_bug.cgi?id=64614 sd_journal_next() is documented as returning '0' if there are no more entries available after the current position. So this sounds like a bug to me. > Do

[systemd-devel] odd seek_tail behaviour

2014-10-12 Thread Daurnimator
Hi All, I was trying to write a program that tailed the journal, but found that sd_journal_seek_tail() didn't work as expected. That is: that it would seek to the last/most recent thing in the journal, and I could tail things from there. I whipped up a quick demonstration program, that shows that