summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--ryu/controller/ofp_event.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/ryu/controller/ofp_event.py b/ryu/controller/ofp_event.py
index 7fb37efd..a0b3a14b 100644
--- a/ryu/controller/ofp_event.py
+++ b/ryu/controller/ofp_event.py
@@ -15,6 +15,7 @@
import inspect
+from ryu import utils
from . import event
@@ -55,9 +56,8 @@ def _create_ofp_msg_ev_class(msg_cls):
def _create_ofp_msg_ev_from_module(modname):
- (f, _s, _t) = modname.rpartition('.')
- mod = __import__(modname, fromlist=[f])
- print mod
+ mod = utils.import_module(modname)
+ # print mod
for _k, cls in mod.__dict__.items():
if not inspect.isclass(cls):
continue