diff libpurple/dbus-analyze-functions.py @ 21038:ec9c30ce628d

Silence warnings from dbus-analyze-functions.py about calling 'raise' on a string (which is deprecated) by raising a stub exception instead.
author Will Thompson <will.thompson@collabora.co.uk>
date Sun, 28 Oct 2007 16:30:10 +0000
parents 93d10000432e
children 7ec5b5724a05
line wrap: on
line diff
--- a/libpurple/dbus-analyze-functions.py	Sat Oct 27 17:47:48 2007 +0000
+++ b/libpurple/dbus-analyze-functions.py	Sun Oct 28 16:30:10 2007 +0000
@@ -75,7 +75,11 @@
 ]
 
 pointer = "#pointer#"
-myexception = "My Exception"
+
+class MyException(Exception):
+    pass
+
+myexception = MyException()
 
 def ctopascal(name):
     newname = ""
@@ -520,7 +524,7 @@
 
             try:
                 self.processfunction(functiontext, paramtexts)
-            except myexception:
+            except MyException:
                 sys.stderr.write(myline + "\n")
             except:
                 sys.stderr.write(myline + "\n")