* [PATCH] unit/hfp: Fix wrong check
@ 2014-10-28 13:24 Andrei Emeltchenko
2014-10-30 9:30 ` Szymon Janc
0 siblings, 1 reply; 2+ messages in thread
From: Andrei Emeltchenko @ 2014-10-28 13:24 UTC (permalink / raw)
To: linux-bluetooth
From: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
---
unit/test-hfp.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/unit/test-hfp.c b/unit/test-hfp.c
index 24ea402..c11a424 100644
--- a/unit/test-hfp.c
+++ b/unit/test-hfp.c
@@ -154,8 +154,7 @@ static gboolean send_pdu(gpointer user_data)
ssize_t len;
pdu = &context->data->pdu_list[context->pdu_offset++];
-
- if (pdu && !pdu->valid)
+ if (!pdu || !pdu->valid)
return FALSE;
len = write(context->fd_server, pdu->data, pdu->size);
--
1.9.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] unit/hfp: Fix wrong check
2014-10-28 13:24 [PATCH] unit/hfp: Fix wrong check Andrei Emeltchenko
@ 2014-10-30 9:30 ` Szymon Janc
0 siblings, 0 replies; 2+ messages in thread
From: Szymon Janc @ 2014-10-30 9:30 UTC (permalink / raw)
To: Andrei Emeltchenko; +Cc: linux-bluetooth
Hi Andrei,
On Tuesday 28 of October 2014 15:24:48 Andrei Emeltchenko wrote:
> From: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
>
> ---
> unit/test-hfp.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/unit/test-hfp.c b/unit/test-hfp.c
> index 24ea402..c11a424 100644
> --- a/unit/test-hfp.c
> +++ b/unit/test-hfp.c
> @@ -154,8 +154,7 @@ static gboolean send_pdu(gpointer user_data)
> ssize_t len;
>
> pdu = &context->data->pdu_list[context->pdu_offset++];
> -
> - if (pdu && !pdu->valid)
> + if (!pdu || !pdu->valid)
> return FALSE;
>
> len = write(context->fd_server, pdu->data, pdu->size);
Patch applied after fixing commit prefix, thanks.
--
BR
Szymon Janc
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-10-30 9:30 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-10-28 13:24 [PATCH] unit/hfp: Fix wrong check Andrei Emeltchenko
2014-10-30 9:30 ` Szymon Janc
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).