diff options
author | hashimoto <hashimoto@chromium.org> | 2015-03-29 23:52:21 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-03-30 06:53:12 +0000 |
commit | 9aa653d4ac52f2c89bfa5164a5eddd8164bb9987 (patch) | |
tree | 2f49fcb1fb8d3a9199b1987ddbc3a0efba146090 /dbus/util.h | |
parent | b306439a4bf1a6bec2658994a9529e305f553148 (diff) | |
download | chromium_src-9aa653d4ac52f2c89bfa5164a5eddd8164bb9987.zip chromium_src-9aa653d4ac52f2c89bfa5164a5eddd8164bb9987.tar.gz chromium_src-9aa653d4ac52f2c89bfa5164a5eddd8164bb9987.tar.bz2 |
Stop deleting ObjectProxy::OnPendingCallIsCompleteData manually
Instead, let libdbus handle it.
This also makes it easier to implement method call cancellation.
BUG=471175
Review URL: https://codereview.chromium.org/1032263002
Cr-Commit-Position: refs/heads/master@{#322746}
Diffstat (limited to 'dbus/util.h')
-rw-r--r-- | dbus/util.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/dbus/util.h b/dbus/util.h index b983b6f..b05834d 100644 --- a/dbus/util.h +++ b/dbus/util.h @@ -23,6 +23,13 @@ CHROME_DBUS_EXPORT std::string GetAbsoluteMemberName( const std::string& interface_name, const std::string& member_name); +// Similar to base::DeletePointer, but takes void* as an argument. +// Used as DBusFreeFunction. +template<typename T> +void DeleteVoidPointer(void* memory) { + delete static_cast<T*>(memory); +} + } // namespace dbus #endif // DBUS_UTIL_H_ |