Add a small input check
authorMikael Berthe <mikael@lilotux.net>
Sat, 21 Jun 2008 20:31:38 +0200
changeset 9 91f9fe1adf0c
parent 8 14dd3f4fd4dc
child 10 cf31fa2e0bbc
Add a small input check
mcevent.py
--- a/mcevent.py	Sat Jun 21 20:27:32 2008 +0200
+++ b/mcevent.py	Sat Jun 21 20:31:38 2008 +0200
@@ -150,6 +150,10 @@
         import os
 
         jid = arg2
+        if not jid:
+            print "Ignoring invalid MSG event line."
+            return
+
         buddy = get_nick(jid)
         if jid in contact_custom_msg:
             msg = contact_custom_msg[jid]