Re: [PATCH obexd] MAP: Fix invalid oflag check

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Sunil,

On Fri, Aug 17, 2012 at 12:33 PM, Sunil Kumar Behera
<sunil.behera@xxxxxxxxxxx> wrote:
> Change logic to check for O_WRONLY, as oflag is
> created by an OR operation of O_WRONLY, O_CREAT and
> O_TRUNC.
> Message update is a PUT function, this check returns
> bad response if GET is received.
> ---
>  plugins/mas.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/plugins/mas.c b/plugins/mas.c
> index 30e529f..57d9611 100644
> --- a/plugins/mas.c
> +++ b/plugins/mas.c
> @@ -632,7 +632,7 @@ static void *message_update_open(const char *name, int oflag, mode_t mode,
>
>         DBG("");
>
> -       if (oflag != O_WRONLY) {
> +       if (oflag == O_RDONLY) {
>                 *err = -EBADR;
>                 return NULL;
>         }
> --
> 1.7.9.5

Pushed upstream, thanks.


-- 
Luiz Augusto von Dentz
--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux