From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: "GONG, Ruiqi" <gongruiqi@huaweicloud.com>
Cc: Kees Cook <keescook@chromium.org>, Arnd Bergmann <arnd@arndb.de>,
linux-kernel@vger.kernel.org, gongruiqi1@huawei.com
Subject: Re: [PATCH] lkdtm: use the return value of strim()
Date: Tue, 22 Aug 2023 14:03:46 +0200 [thread overview]
Message-ID: <2023082228-breath-submitter-7a1e@gregkh> (raw)
In-Reply-To: <20230817142117.972418-1-gongruiqi@huaweicloud.com>
On Thu, Aug 17, 2023 at 10:21:17PM +0800, GONG, Ruiqi wrote:
> From: "GONG, Ruiqi" <gongruiqi1@huawei.com>
>
> Make use of the return value of strim() to achieve left-trim as well as
> right-trim, which prevents the following unusual fail case:
>
> # echo " EXCEPTION" > /sys/kernel/debug/provoke-crash/DIRECT
> sh: write error: Invalid argument
And that is correct, don't use leading whitespace, the kernel is not
there to parse it away :)
thanks,
greg k-h
prev parent reply other threads:[~2023-08-22 12:03 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-17 14:21 GONG, Ruiqi
2023-08-17 16:55 ` Kees Cook
2023-08-18 2:39 ` GONG, Ruiqi
2023-08-18 10:44 ` Heiko Carstens
2023-08-22 12:03 ` Greg Kroah-Hartman [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=2023082228-breath-submitter-7a1e@gregkh \
--to=gregkh@linuxfoundation.org \
--cc=arnd@arndb.de \
--cc=gongruiqi1@huawei.com \
--cc=gongruiqi@huaweicloud.com \
--cc=keescook@chromium.org \
--cc=linux-kernel@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
all inboxes | Powered by JetHome®