From: Pavel Machek <pavel@denx.de>
To: Sasha Levin <sashal@kernel.org>
Cc: linux-kernel@vger.kernel.org, stable@vger.kernel.org,
Brenda Streiff <brenda.streiff@ni.com>,
Masahiro Yamada <masahiroy@kernel.org>,
linux-kbuild@vger.kernel.org
Subject: Re: [PATCH AUTOSEL 4.19 06/11] kconfig: let 'shell' return enough output for deep path names
Date: Sun, 20 Feb 2022 11:01:23 +0100 [thread overview]
Message-ID: <20220220100123.GB7321@amd> (raw)
In-Reply-To: <20220215153104.581786-6-sashal@kernel.org>
[-- Attachment #1: Type: text/plain, Size: 855 bytes --]
Hi!
> [ Upstream commit 8a4c5b2a6d8ea079fa36034e8167de87ab6f8880 ]
>
> The 'shell' built-in only returns the first 256 bytes of the command's
> output. In some cases, 'shell' is used to return a path; by bumping up
> the buffer size to 4096 this lets us capture up to PATH_MAX.
If the idea is to support up-to PATH_MAX, perhaps open-coded 4096
should be replaced by PATH_MAX in the code, too?
Best regards,
Pavel
> +++ b/scripts/kconfig/preprocess.c
> @@ -138,7 +138,7 @@ static char *do_lineno(int argc, char *argv[])
> static char *do_shell(int argc, char *argv[])
> {
> FILE *p;
> - char buf[256];
> + char buf[4096];
> char *cmd;
> size_t nread;
> int i;
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]
prev parent reply other threads:[~2022-02-20 10:01 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20220215153104.581786-1-sashal@kernel.org>
2022-02-15 15:30 ` [PATCH AUTOSEL 4.19 06/11] kconfig: let 'shell' return enough output for deep path names Sasha Levin
2022-02-20 10:01 ` Pavel Machek [this message]
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=20220220100123.GB7321@amd \
--to=pavel@denx.de \
--cc=brenda.streiff@ni.com \
--cc=linux-kbuild@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=masahiroy@kernel.org \
--cc=sashal@kernel.org \
--cc=stable@vger.kernel.org \
/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