summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthew Johnson <mjj29@hecate.matthew.ath.cx>2008-05-14 23:30:43 +0100
committerMatthew Johnson <mjj29@hecate.matthew.ath.cx>2008-05-14 23:30:43 +0100
commit97a2c200241def7c265446adcb978d3a049a78f1 (patch)
tree31624021945707e2b5cdf9cd27768e98cd7bd4e4
parentfb8145158aefc9c6e7de5b4ad679e5c9dcbc0530 (diff)
* Fix dynamic introspection of objects which export the same
interface multiple times (Patch fromSveinung Kvilhaugsvik <sveinung84 -at- users -dot- sourceforge -dot- net>)
-rw-r--r--changelog3
-rw-r--r--org/freedesktop/dbus/DBusConnection.java4
2 files changed, 6 insertions, 1 deletions
diff --git a/changelog b/changelog
index 9ff4efe..2fa7750 100644
--- a/changelog
+++ b/changelog
@@ -5,6 +5,9 @@ Version 2.4.1:
* Fix CreateInterface (Spotted by Tom Walsh <walshtc -at- gmail -dot- com>)
* Fix serial assignment race condition (Spotted by Ed Wei
<Edward.Wei.03 -at- alum -dot- dartmouth -dot- org>)
+ * Fix dynamic introspection of objects which export the same
+ interface multiple times (Patch from Sveinung Kvilhaugsvik
+ <sveinung84 -at- users -dot- sourceforge -dot- net>)
Version 2.4:
diff --git a/org/freedesktop/dbus/DBusConnection.java b/org/freedesktop/dbus/DBusConnection.java
index 3fc6007..2ee444a 100644
--- a/org/freedesktop/dbus/DBusConnection.java
+++ b/org/freedesktop/dbus/DBusConnection.java
@@ -200,7 +200,9 @@ public class DBusConnection extends AbstractConnection
int j = 0;
while (j >= 0) {
try {
- ifcs.add(Class.forName(iface));
+ Class ifclass = Class.forName(iface);
+ if (!ifcs.contains(ifclass))
+ ifcs.add(ifclass);
break;
} catch (Exception e) {}
j = iface.lastIndexOf(".");