Message ID | 20230421024731.42130-1-aarongt.shen@gmail.com |
---|---|
State | New |
Headers | show |
Series | [Bluez] obexd: agent: Use if-elseif instead of multi-if to check error message | expand |
diff --git a/obexd/src/manager.c b/obexd/src/manager.c index 2bb985b96..73fd6b9af 100644 --- a/obexd/src/manager.c +++ b/obexd/src/manager.c @@ -632,8 +632,7 @@ static void agent_reply(DBusPendingCall *call, void *user_data) if (dbus_error_has_name(&derr, DBUS_ERROR_NO_REPLY)) agent_cancel(); - - if (dbus_error_has_name(&derr, OBEX_ERROR_REJECT)) + else if (dbus_error_has_name(&derr, OBEX_ERROR_REJECT)) agent->auth_reject = TRUE; dbus_error_free(&derr);