projects
/
platform
/
upstream
/
bluez.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
65580ef
)
obexd: agent: Use if-elseif instead of multi-if to check error message
author
Guiting Shen
<aarongt.shen@gmail.com>
Fri, 21 Apr 2023 02:47:31 +0000
(10:47 +0800)
committer
Ayush Garg
<ayush.garg@samsung.com>
Fri, 5 Jan 2024 10:41:34 +0000
(16:11 +0530)
The obex agent will return only one error message at the same time.So
we should use if-elseif instead of multi-if to check error message which
maybe DEBUG_ERROR_NO_REPLY or OBEX_ERROR_REJECT in agent_reply().
obexd/src/manager.c
patch
|
blob
|
history
diff --git
a/obexd/src/manager.c
b/obexd/src/manager.c
index
22000d8
..
5c9f532
100755
(executable)
--- a/
obexd/src/manager.c
+++ b/
obexd/src/manager.c
@@
-765,8
+765,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);