python-systemd/3d046016c4ca8860485ab27dd42eaf5bc49872a7.patch

23 lines
849 B
Diff
Raw Normal View History

2016-01-24 21:01:31 +00:00
From 3d046016c4ca8860485ab27dd42eaf5bc49872a7 Mon Sep 17 00:00:00 2001
From: Michael Herold <m.herold@fu-berlin.de>
Date: Thu, 10 Dec 2015 00:18:01 +0100
Subject: [PATCH] Fixes Reader.seek_monotonic(datetime.timedelta)
---
systemd/journal.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/systemd/journal.py b/systemd/journal.py
index b319a8a..fae7f6f 100644
--- a/systemd/journal.py
+++ b/systemd/journal.py
@@ -291,7 +291,7 @@ def seek_monotonic(self, monotonic, bootid=None):
is reference to. Defaults to current bootid.
"""
if isinstance(monotonic, _datetime.timedelta):
- monotonic = monotonic.totalseconds()
+ monotonic = monotonic.total_seconds()
monotonic = int(monotonic * 1000000)
if isinstance(bootid, _uuid.UUID):
bootid = bootid.hex