summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/event.py
diff options
context:
space:
mode:
authorBernhard Reutner-Fischer <rep.dot.nop@gmail.com>2011-01-03 20:57:23 +0100
committerRichard Purdie <rpurdie@linux.intel.com>2011-01-04 15:00:22 +0000
commitc0a11db8777eab89bcae3482fcc075a8f6a6aa2a (patch)
tree8146d2a537df8b480f74c2956b3fb577670a6a6f /bitbake/lib/bb/event.py
parentaae85325289a83d21606621310894d5d6f56b50a (diff)
downloadpoky-c0a11db8777eab89bcae3482fcc075a8f6a6aa2a.tar.gz
event: fix unicode handler registration
(Bitbake rev: 413af91e56a6d2368f6cbe22c0e2a337e1289e55) Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'bitbake/lib/bb/event.py')
-rw-r--r--bitbake/lib/bb/event.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/bitbake/lib/bb/event.py b/bitbake/lib/bb/event.py
index 1d0fb7bfd1..3866e01f2b 100644
--- a/bitbake/lib/bb/event.py
+++ b/bitbake/lib/bb/event.py
@@ -147,7 +147,7 @@ def register(name, handler):
147 147
148 if handler is not None: 148 if handler is not None:
149 # handle string containing python code 149 # handle string containing python code
150 if type(handler).__name__ == "str": 150 if isinstance(handler, basestring):
151 tmp = "def tmpHandler(e):\n%s" % handler 151 tmp = "def tmpHandler(e):\n%s" % handler
152 comp = bb.utils.better_compile(tmp, "tmpHandler(e)", "bb.event._registerCode") 152 comp = bb.utils.better_compile(tmp, "tmpHandler(e)", "bb.event._registerCode")
153 _handlers[name] = comp 153 _handlers[name] = comp