diff options
author | Julia Cartwright <julia@ni.com> | 2018-12-20 14:44:56 -0600 |
---|---|---|
committer | Julia Cartwright <julia@ni.com> | 2018-12-20 14:44:56 -0600 |
commit | c81e797febc36da8f0fc85408b5927ed8c69e2af (patch) | |
tree | e2f6593eb28c715d56ad507a64c011f64c517bdb /fs | |
parent | b1531bb9ff88f8f0da8bb7cd337cd300f4da7867 (diff) | |
parent | 94c67449c7550597e86f15cce923055f7b2c8e09 (diff) |
Merge tag 'v4.9.116' into v4.9-rt
This is the 4.9.116 stable release
Diffstat (limited to 'fs')
-rw-r--r-- | fs/exec.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/fs/exec.c b/fs/exec.c index 71f4c6ec2bb8..07be2e76ff3c 100644 --- a/fs/exec.c +++ b/fs/exec.c @@ -1230,15 +1230,14 @@ killed: return -EAGAIN; } -char *get_task_comm(char *buf, struct task_struct *tsk) +char *__get_task_comm(char *buf, size_t buf_size, struct task_struct *tsk) { - /* buf must be at least sizeof(tsk->comm) in size */ task_lock(tsk); - strncpy(buf, tsk->comm, sizeof(tsk->comm)); + strncpy(buf, tsk->comm, buf_size); task_unlock(tsk); return buf; } -EXPORT_SYMBOL_GPL(get_task_comm); +EXPORT_SYMBOL_GPL(__get_task_comm); /* * These functions flushes out all traces of the currently running executable |