From: Bastien Nocera <hadess@hadess.net>
To: Zhiyuan Sheng <zhiyuan.sheng@oss.qualcomm.com>,
linux-bluetooth@vger.kernel.org
Cc: cheng.jiang@oss.qualcomm.com, shuai.zhang@oss.qualcomm.com
Subject: Re: [PATCH v1] obexd: fix PBAP PullPhoneBook failure with ebook backend
Date: Fri, 05 Jun 2026 11:39:19 +0200 [thread overview]
Message-ID: <72fce9d0891c39adfac228ebe213af6a62f50c65.camel@hadess.net> (raw)
In-Reply-To: <20260522060312.1503481-1-zhiyuan.sheng@oss.qualcomm.com>
On Fri, 2026-05-22 at 14:03 +0800, Zhiyuan Sheng wrote:
> phonebook_pull() in phonebook-ebook.c does not set *err = 0 on the
> success path, unlike phonebook-tracker.c and phonebook-dummy.c. The
> caller vobject_pull_open() in pbap.c declares 'ret' without
> initialization and passes &ret to phonebook_pull(), so 'ret' retains
> an indeterminate stack value when the ebook backend is in use. The
> subsequent 'if (ret < 0)' check then incorrectly triggers and rejects
> the request with Internal Server Error.
>
> Fix this by setting *err = 0 on success in phonebook-ebook.c, and
> initialize 'ret' to 0 in vobject_pull_open() as a defensive measure
> to guard against any backend that omits this assignment.
>
> Signed-off-by: Zhiyuan Sheng <zhiyuan.sheng@oss.qualcomm.com>
Looks good to me
next prev parent reply other threads:[~2026-06-05 9:39 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-22 6:03 [PATCH v1] obexd: fix PBAP PullPhoneBook failure with ebook backend Zhiyuan Sheng
2026-05-22 8:51 ` [v1] " bluez.test.bot
2026-06-05 9:39 ` Bastien Nocera [this message]
2026-06-05 16:30 ` [PATCH v1] " patchwork-bot+bluetooth
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=72fce9d0891c39adfac228ebe213af6a62f50c65.camel@hadess.net \
--to=hadess@hadess.net \
--cc=cheng.jiang@oss.qualcomm.com \
--cc=linux-bluetooth@vger.kernel.org \
--cc=shuai.zhang@oss.qualcomm.com \
--cc=zhiyuan.sheng@oss.qualcomm.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox