Commit 6db9d317 authored by Li zeming's avatar Li zeming Committed by Andrew Morton

user_namespace: remove unnecessary NULL values from kbuf

kbuf is assigned first, so it does not need to initialize the assignment.

Link: https://lkml.kernel.org/r/20240115062519.31298-1-zeming@nfschina.comSigned-off-by: default avatarLi zeming <zeming@nfschina.com>
Cc: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
parent f9436a5d
...@@ -931,7 +931,7 @@ static ssize_t map_write(struct file *file, const char __user *buf, ...@@ -931,7 +931,7 @@ static ssize_t map_write(struct file *file, const char __user *buf,
struct uid_gid_map new_map; struct uid_gid_map new_map;
unsigned idx; unsigned idx;
struct uid_gid_extent extent; struct uid_gid_extent extent;
char *kbuf = NULL, *pos, *next_line; char *kbuf, *pos, *next_line;
ssize_t ret; ssize_t ret;
/* Only allow < page size writes at the beginning of the file */ /* Only allow < page size writes at the beginning of the file */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment