mirror of
https://gitlab.freedesktop.org/dbus/dbus.git
synced 2025-12-25 02:20:08 +01:00
test: Simplify error checking path in test-service slightly
This should shut up Coverity from complaining about not checking the return value of dbus_set_error_from_message(), which is equivalent to the (type == DBUS_MESSAGE_TYPE_ERROR) check. Coverity ID: 54697 Signed-off-by: Philip Withnall <withnall@endlessm.com> Bug: https://bugs.freedesktop.org/show_bug.cgi?id=99723 Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
This commit is contained in:
parent
84cd6243b3
commit
f88c8a8c39
1 changed files with 1 additions and 2 deletions
|
|
@ -92,9 +92,8 @@ check_hello_from_self_reply (DBusPendingCall *pcall,
|
|||
|
||||
dbus_message_unref (echo_reply);
|
||||
}
|
||||
else if (type == DBUS_MESSAGE_TYPE_ERROR)
|
||||
else if (dbus_set_error_from_message (&error, reply))
|
||||
{
|
||||
dbus_set_error_from_message (&error, reply);
|
||||
printf ("Error type in reply: %s\n", error.message);
|
||||
|
||||
if (strcmp (error.name, DBUS_ERROR_NO_MEMORY) != 0)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue