From 28a418ad5de4f76a0b9202588152cac4a73edd61 Mon Sep 17 00:00:00 2001 From: Ryan Lortie Date: Fri, 11 Mar 2005 18:15:25 +0000 Subject: This commit was manufactured by cvs2svn to create tag 'dbus-0.23.4'. --- dbus/dbus-pending-call.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'dbus/dbus-pending-call.c') diff --git a/dbus/dbus-pending-call.c b/dbus/dbus-pending-call.c index 546f42a6..3844e473 100644 --- a/dbus/dbus-pending-call.c +++ b/dbus/dbus-pending-call.c @@ -290,6 +290,24 @@ dbus_pending_call_steal_reply (DBusPendingCall *pending) return message; } +/** + * Gets the reply, or returns #NULL if none has been received yet. The + * reference count is not incremented on the returned message, so you + * have to keep a reference count on the pending call (or add one + * to the message). + * + * @todo not thread safe? I guess it has to lock though it sucks + * @todo maybe to make this threadsafe, it should be steal_reply(), i.e. only one thread can ever get the message + * + * @param pending the pending call + * @returns the reply message or #NULL. + */ +DBusMessage* +dbus_pending_call_get_reply (DBusPendingCall *pending) +{ + return pending->reply; +} + /** * Block until the pending call is completed. The blocking is as with * dbus_connection_send_with_reply_and_block(); it does not enter the -- cgit