Skip to content
Snippets Groups Projects
Commit 47afd7ae authored by Yue Hu's avatar Yue Hu Committed by Kees Cook
Browse files

pstore/ram: Add kmsg hlen zero check to ramoops_pstore_write()


If zero-length header happened in ramoops_write_kmsg_hdr(), that means
we will not be able to read back dmesg record later, since it will be
treated as invalid header in ramoops_pstore_read(). So we should not
execute the following code but return the error.

Signed-off-by: default avatarYue Hu <huyue2@yulong.com>
Signed-off-by: default avatarKees Cook <keescook@chromium.org>
parent 1e0f67a9
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment