]> git.baikalelectronics.ru Git - kernel.git/commit
proc: less code duplication in /proc/*/cmdline
authorAlexey Dobriyan <adobriyan@gmail.com>
Fri, 24 Feb 2017 23:00:20 +0000 (15:00 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Sat, 25 Feb 2017 01:46:56 +0000 (17:46 -0800)
commit32087023e90b474e3c3f39f5cd98137076e0464a
tree9a0b2cc6c820ada2db8d66ba74fff319ac0bf10c
parent323d9335a6b2c712bc617d8be73cdf31b5331e11
proc: less code duplication in /proc/*/cmdline

After staring at this code for a while I've figured using small 2-entry
array describing ARGV and ENVP is the way to address code duplication
critique.

Link: http://lkml.kernel.org/r/20170105185724.GA12027@avx2
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/proc/base.c