Bug 45459 - Add tp_connection_disconnect_async()
Summary: Add tp_connection_disconnect_async()
Status: RESOLVED FIXED
Alias: None
Product: Telepathy
Classification: Unclassified
Component: tp-glib (show other bugs)
Version: git master
Hardware: Other All
: medium enhancement
Assignee: Simon McVittie
QA Contact: Telepathy bugs list
URL: http://cgit.freedesktop.org/~smcv/tel...
Whiteboard: review+
Keywords: patch
Depends on:
Blocks: 22207
  Show dependency treegraph
 
Reported: 2012-01-31 11:54 UTC by Simon McVittie
Modified: 2012-02-01 04:42 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description Simon McVittie 2012-01-31 11:54:34 UTC
Disconnecting connections is sometimes something you want to do, and the regression tests do a lot of it. Let's have an async method for this.

(This makes deletion of the _run_ methods on the 'next' branch easier, and there seems no reason not to have the API addition on master.)
Comment 1 Jonny Lamb 2012-01-31 12:25:23 UTC
+ g_simple_async_result_complete_in_idle (result);

In what case will tp_cli_connection_call_disconnect return immediately? This is so annoying that we have to do this...

Otherwise, looks good.
Comment 2 Simon McVittie 2012-01-31 12:38:32 UTC
(In reply to comment #1)
> In what case will tp_cli_connection_call_disconnect return immediately?

If the D-Bus interface is missing (impossible here because it's the core interface) or the proxy has been invalidated (but I might be misremembering that second one, I'll have to check).

If I'm right about the second one, I'm pretty sure other places in tp-glib get this wrong. I'll check.

Making tp_cli_*_call_* always-async is on my list to be done early for 1.0, even if we end up deleting them and replacing them with GDBus or GAsyncBadgers or whatever before the API actually freezes. The sometimes-sync is allegedly an API guarantee (as in, the tests test it) but I hope nobody relies on it anyway...
Comment 3 Jonny Lamb 2012-01-31 12:42:30 UTC
(In reply to comment #2)
> The sometimes-sync is allegedly an API guarantee (as in, the tests
> test it) but I hope nobody relies on it anyway...

Hilarious!

Feel free to merge.
Comment 4 Simon McVittie 2012-02-01 04:42:24 UTC
Fixed in git for 0.17.4


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.