Merge lp:~thomas-voss/dbus-cpp/fix-1396985 into lp:dbus-cpp

Proposed by Thomas Voß on 2014-11-27
Status: Merged
Approved by: Thomas Voß on 2015-01-23
Approved revision: 93
Merged at revision: 92
Proposed branch: lp:~thomas-voss/dbus-cpp/fix-1396985
Merge into: lp:dbus-cpp
Diff against target: 14 lines (+3/-1)
1 file modified
src/core/dbus/bus.cpp (+3/-1)
To merge this branch: bzr merge lp:~thomas-voss/dbus-cpp/fix-1396985
Reviewer Review Type Date Requested Status
PS Jenkins bot continuous-integration Approve on 2014-11-27
Antti Kaijanmäki (community) 2014-11-27 Approve on 2014-11-27
Review via email: mp+243063@code.launchpad.net

Commit Message

We ref on construction, so decrement the ref count by 1 to 1 prior to returning.

Description of the Change

We ref on construction, so decrement the ref count by 1 to 1 prior to returning.

To post a comment you must log in.
lp:~thomas-voss/dbus-cpp/fix-1396985 updated on 2014-11-27
93. By Thomas Voß on 2014-11-27

Move unref to new line.

Antti Kaijanmäki (kaijanmaki) wrote :

LGTM.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/core/dbus/bus.cpp'
2--- src/core/dbus/bus.cpp 2014-10-30 13:22:52 +0000
3+++ src/core/dbus/bus.cpp 2014-11-27 16:38:59 +0000
4@@ -278,7 +278,9 @@
5 if (!result)
6 throw std::runtime_error(se.print());
7
8- return Message::from_raw_message(result);
9+ auto reply = Message::from_raw_message(result);
10+ dbus_message_unref(result);
11+ return reply;
12 }
13
14 PendingCall::Ptr Bus::send_with_reply_and_timeout(

Subscribers

People subscribed via source and target branches