src/idmapped-mounts: use renameat instead of renameat2
authorYang Xu <xuyang2018.jy@fujitsu.com>
Sun, 25 Apr 2021 10:02:39 +0000 (18:02 +0800)
committerEryu Guan <guaneryu@gmail.com>
Sun, 9 May 2021 13:50:19 +0000 (21:50 +0800)
commitaea877f8979e802ffa7bac7ff23303a567f1aacf
treeef798ffeb0aaf84dae3deecade172f14ea73831b
parent51b3e9ece6c832fe8ee1c21103844fd6ee58f68b
src/idmapped-mounts: use renameat instead of renameat2

We don't add fallback for renameat2, so it build failed on old
kernel.  Also, renameat2() man-pages said as below:

"renameat2() has an additional flags argument.  A renameat2() call
with a zero flags argument is equivalent to renameat()."

In this src file, we use zero flag for all renameat2 call. So we use
renameat directly.

Signed-off-by: Yang Xu <xuyang2018.jy@fujitsu.com>
Reviewed-by: Christian Brauner <christian.brauner@ubuntu.com>
Reviewed-by:Anju T Sudhakar<anju@linux.vnet.ibm.com>
Signed-off-by: Eryu Guan <guaneryu@gmail.com>
src/idmapped-mounts/idmapped-mounts.c