dup2: Fix two bugs
authorAlan Cox <alan@linux.intel.com>
Sat, 22 Dec 2018 11:17:38 +0000 (11:17 +0000)
committerAlan Cox <alan@linux.intel.com>
Sat, 22 Dec 2018 11:17:38 +0000 (11:17 +0000)
commit014946e511a68071c45fac3872d0a5ba25e2cc15
tree9a8f2032a77207c4bd0064c372e14d122a121810
parent39ed83ef5153f661deb16bba8654a4da4040ffb2
dup2: Fix two bugs

1. dup2(x,x) corrupted all the counts we closed the object then referenced
it

2. dup2() returns the new file handle not 0 on success
Kernel/syscall_fs.c