mirror of
https://gitlab.freedesktop.org/dbus/dbus.git
synced 2026-05-05 13:28:02 +02:00
DBusPendingCall: Improve doc-comments around completed flag
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=102839 Signed-off-by: Simon McVittie <smcv@collabora.com> Reviewed-by: Philip Withnall <withnall@endlessm.com>
This commit is contained in:
parent
d3e03eb50e
commit
57a0cf1d14
1 changed files with 19 additions and 2 deletions
|
|
@ -75,8 +75,16 @@ struct DBusPendingCall
|
|||
|
||||
dbus_uint32_t reply_serial; /**< Expected serial of reply */
|
||||
|
||||
unsigned int completed : 1; /**< TRUE if completed */
|
||||
unsigned int timeout_added : 1; /**< Have added the timeout */
|
||||
/**
|
||||
* TRUE if some thread has taken responsibility for completing this
|
||||
* pending call: either the pending call has completed, or it is about
|
||||
* to be completed. Protected by the connection lock.
|
||||
*/
|
||||
unsigned int completed : 1;
|
||||
/**
|
||||
* TRUE if we have added the timeout. Protected by the connection lock.
|
||||
*/
|
||||
unsigned int timeout_added : 1;
|
||||
};
|
||||
|
||||
static void
|
||||
|
|
@ -196,6 +204,11 @@ _dbus_pending_call_set_reply_unlocked (DBusPendingCall *pending,
|
|||
/**
|
||||
* Sets the pending call to completed
|
||||
*
|
||||
* This method is called with the connection lock held, to protect
|
||||
* pending->completed. It must be paired with a call to
|
||||
* _dbus_pending_call_finish_completion() after the connection lock has
|
||||
* been released.
|
||||
*
|
||||
* @param pending the pending call
|
||||
*/
|
||||
void
|
||||
|
|
@ -209,6 +222,10 @@ _dbus_pending_call_start_completion_unlocked (DBusPendingCall *pending)
|
|||
/**
|
||||
* Call the notifier function for the pending call.
|
||||
*
|
||||
* This method must be called after the connection lock has been
|
||||
* released, and must be paired with a call to
|
||||
* _dbus_pending_call_start_completion_unlocked().
|
||||
*
|
||||
* @param pending the pending call
|
||||
*/
|
||||
void
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue