All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tuomas Suutari <thsuut@utu.fi>
To: BlueZ development <bluez-devel@lists.sourceforge.net>
Subject: Re: [Bluez-devel] rfcomm_sock_sendmsg with len==0 (in Linux 2.6.18)
Date: Tue, 19 Dec 2006 11:47:39 +0200	[thread overview]
Message-ID: <200612191147.39325.thsuut@utu.fi> (raw)
In-Reply-To: <1166521154.29972.4.camel@violet>

On 2006-12-19 Tuesday 11:39, Marcel Holtmann wrote:
> > rfcomm_sock_sendmsg() in net/bluetooth/rfcomm/sock.c. It returns
> > uninitialized variable err, if called with len==0.
> >
> > Simple fix is to initialize err to 0.
>
> this would only hide the real problem. It should only return err if
> the sent is still 0. The return statement is
>
> 	return sent ? sent : err;

Yep, exactly. It returns err, which isn't initialized, so it could be 
positive.

Am I missing something?

-- 
Tuomas Suutari | +358 50 3806983 | thsuut@utu.fi

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Bluez-devel mailing list
Bluez-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-devel

  reply	other threads:[~2006-12-19  9:47 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-12-19  9:03 [Bluez-devel] rfcomm_sock_sendmsg with len==0 (in Linux 2.6.18) Tuomas Suutari
2006-12-19  9:39 ` Marcel Holtmann
2006-12-19  9:47   ` Tuomas Suutari [this message]
2006-12-19 10:31     ` Marcel Holtmann
2006-12-19 10:41       ` Luciano Coelho
2006-12-19 10:57       ` Tuomas Suutari

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200612191147.39325.thsuut@utu.fi \
    --to=thsuut@utu.fi \
    --cc=bluez-devel@lists.sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.