Patch "kconfig: let 'shell' return enough output for deep path names" has been added to the 5.10-stable tree

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

 



This is a note to let you know that I've just added the patch titled

    kconfig: let 'shell' return enough output for deep path names

to the 5.10-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     kconfig-let-shell-return-enough-output-for-deep-path.patch
and it can be found in the queue-5.10 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 07db88a9aea415123e9bf90a2991b404b640d404
Author: Brenda Streiff <brenda.streiff@xxxxxx>
Date:   Fri Jan 28 16:01:28 2022 -0600

    kconfig: let 'shell' return enough output for deep path names
    
    [ 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.
    
    The specific case where I ran into this was due to commit 1e860048c53e
    ("gcc-plugins: simplify GCC plugin-dev capability test"). After this
    change, we now use `$(shell,$(CC) -print-file-name=plugin)` to return
    a path; if the gcc path is particularly long, then the path ends up
    truncated at the 256 byte mark, which makes the HAVE_GCC_PLUGINS
    depends test always fail.
    
    Signed-off-by: Brenda Streiff <brenda.streiff@xxxxxx>
    Signed-off-by: Masahiro Yamada <masahiroy@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/scripts/kconfig/preprocess.c b/scripts/kconfig/preprocess.c
index 0590f86df6e40..748da578b418c 100644
--- a/scripts/kconfig/preprocess.c
+++ b/scripts/kconfig/preprocess.c
@@ -141,7 +141,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;



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux