]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
bitbake: knotty: make it possible to use termfilter without either console
authorPaul Eggleton <paul.eggleton@linux.intel.com>
Wed, 19 Jul 2017 09:56:05 +0000 (11:56 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 21 Jul 2017 07:41:12 +0000 (08:41 +0100)
This isn't useful for knotty itself, but for use from tinfoil
in case we can't get access to either the console or errconsole, allow
either to be unspecified (None).

(Bitbake rev: 7544de437fc66b81502ecdb5db859182c45827cb)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
bitbake/lib/bb/ui/knotty.py

index c3019822c423b6daf27295da74d3cca4a81ac58a..f3900bdd059fe72ecf84bb1ce81b4bf21fe2049b 100644 (file)
@@ -207,8 +207,10 @@ class TerminalFilter(object):
             self.interactive = False
             bb.note("Unable to use interactive mode for this terminal, using fallback")
             return
-        console.addFilter(InteractConsoleLogFilter(self, format))
-        errconsole.addFilter(InteractConsoleLogFilter(self, format))
+        if console:
+            console.addFilter(InteractConsoleLogFilter(self, format))
+        if errconsole:
+            errconsole.addFilter(InteractConsoleLogFilter(self, format))
 
         self.main_progress = None