diff options
author | Vinicius Costa Gomes <vinicius.gomes@openbossa.org> | 2008-09-09 15:18:27 -0300 |
---|---|---|
committer | Vinicius Costa Gomes <vinicius.gomes@openbossa.org> | 2008-09-09 19:47:14 -0300 |
commit | c0296a9dde463495975140e7fb7f689a347807d6 (patch) | |
tree | 8db2fe54052fa2566d0ce365842e96943c104b35 /src/agent.c | |
parent | 8b783303433f7c25c2a888034a6da369a7e9a731 (diff) |
Cancels the pending request from agent side when receiving a NoReply
Diffstat (limited to 'src/agent.c')
-rw-r--r-- | src/agent.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/agent.c b/src/agent.c index e8f9c651..6b7c8d03 100644 --- a/src/agent.c +++ b/src/agent.c @@ -285,6 +285,14 @@ static void simple_agent_reply(DBusPendingCall *call, void *user_data) err.name, err.message); cb(agent, &err, req->user_data); + + if (dbus_error_has_name(&err, DBUS_ERROR_NO_REPLY)) { + agent_cancel(agent); + dbus_message_unref(message); + dbus_error_free(&err); + return; + } + dbus_error_free(&err); goto done; } |