public inbox for linux-bluetooth@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH Bluez] obexd: agent: Use if-elseif instead of multi-if to check error message
@ 2023-04-21  2:47 Guiting Shen
  2023-04-21  4:13 ` [Bluez] " bluez.test.bot
  2023-04-21 21:10 ` [PATCH Bluez] " patchwork-bot+bluetooth
  0 siblings, 2 replies; 3+ messages in thread
From: Guiting Shen @ 2023-04-21  2:47 UTC (permalink / raw)
  To: linux-bluetooth; +Cc: Guiting Shen

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 | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

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);
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* RE: [Bluez] obexd: agent: Use if-elseif instead of multi-if to check error message
  2023-04-21  2:47 [PATCH Bluez] obexd: agent: Use if-elseif instead of multi-if to check error message Guiting Shen
@ 2023-04-21  4:13 ` bluez.test.bot
  2023-04-21 21:10 ` [PATCH Bluez] " patchwork-bot+bluetooth
  1 sibling, 0 replies; 3+ messages in thread
From: bluez.test.bot @ 2023-04-21  4:13 UTC (permalink / raw)
  To: linux-bluetooth, aarongt.shen

[-- Attachment #1: Type: text/plain, Size: 946 bytes --]

This is automated email and please do not reply to this email!

Dear submitter,

Thank you for submitting the patches to the linux bluetooth mailing list.
This is a CI test results with your patch series:
PW Link:https://patchwork.kernel.org/project/bluetooth/list/?series=741938

---Test result---

Test Summary:
CheckPatch                    PASS      0.51 seconds
GitLint                       PASS      0.36 seconds
BuildEll                      PASS      27.08 seconds
BluezMake                     PASS      871.37 seconds
MakeCheck                     PASS      11.83 seconds
MakeDistcheck                 PASS      150.89 seconds
CheckValgrind                 PASS      248.84 seconds
CheckSmatch                   PASS      339.22 seconds
bluezmakeextell               PASS      99.80 seconds
IncrementalBuild              PASS      726.24 seconds
ScanBuild                     PASS      1046.37 seconds



---
Regards,
Linux Bluetooth


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH Bluez] obexd: agent: Use if-elseif instead of multi-if to check error message
  2023-04-21  2:47 [PATCH Bluez] obexd: agent: Use if-elseif instead of multi-if to check error message Guiting Shen
  2023-04-21  4:13 ` [Bluez] " bluez.test.bot
@ 2023-04-21 21:10 ` patchwork-bot+bluetooth
  1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+bluetooth @ 2023-04-21 21:10 UTC (permalink / raw)
  To: Guiting Shen; +Cc: linux-bluetooth

Hello:

This patch was applied to bluetooth/bluez.git (master)
by Luiz Augusto von Dentz <luiz.von.dentz@intel.com>:

On Fri, 21 Apr 2023 10:47:31 +0800 you wrote:
> 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 | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)

Here is the summary with links:
  - [Bluez] obexd: agent: Use if-elseif instead of multi-if to check error message
    https://git.kernel.org/pub/scm/bluetooth/bluez.git/?id=9a0acc7984ef

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2023-04-21 21:10 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-04-21  2:47 [PATCH Bluez] obexd: agent: Use if-elseif instead of multi-if to check error message Guiting Shen
2023-04-21  4:13 ` [Bluez] " bluez.test.bot
2023-04-21 21:10 ` [PATCH Bluez] " patchwork-bot+bluetooth

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox