[elbe-devel] [PATCH 09/10] asciidoclog: enforce to log strings

Manuel Traut manut at linutronix.de
Fri Sep 29 00:11:45 CEST 2017


Signed-off-by: Manuel Traut <manut at linutronix.de>
---
 elbepack/asciidoclog.py | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/elbepack/asciidoclog.py b/elbepack/asciidoclog.py
index f96ed547..9530745e 100644
--- a/elbepack/asciidoclog.py
+++ b/elbepack/asciidoclog.py
@@ -28,7 +28,7 @@ class LogBase(object):
         self.fp = fp
 
     def printo(self, text=""):
-        self.fp.write(text+"\n")
+        self.fp.write("%s\n" % str(text))
 
     def print_raw(self, text):
         self.fp.write(text)
@@ -36,13 +36,13 @@ class LogBase(object):
     def h1(self, text):
         self.printo()
         self.printo(text)
-        self.printo("="*len(text))
+        self.printo("="*len(str(text)))
         self.printo()
 
     def h2(self, text):
         self.printo()
         self.printo(text)
-        self.printo("-"*len(text))
+        self.printo("-"*len(str(text)))
         self.printo()
 
     def table(self):
-- 
2.14.1




More information about the elbe-devel mailing list