rename: perform user mode dir loop check when not done in kernel
authorBill Zissimopoulos <billziss@navimatics.com>
Tue, 5 Jun 2018 22:29:57 +0000 (15:29 -0700)
committerNikolaus Rath <Nikolaus@rath.org>
Thu, 7 Jun 2018 09:17:12 +0000 (10:17 +0100)
commita0c14264e99491406f8a346b50903dadaccaa6f8
tree0a33f6645b09d18a9c5391071187ff215bbb84b9
parentc17f2c6823a21796678a228bfe4971719aced1e7
rename: perform user mode dir loop check when not done in kernel
    Linux performs the dir loop check (rename(a, a/b/c)
    or rename(a/b/c, a), etc.) in kernel. Unfortunately
    other systems do not perform this check (e.g. FreeBSD).
    This results in a deadlock in get_path2, because libfuse
    did not expect to handle such cases.

    We add a check_dir_loop function that performs the dir
    loop check in user mode and enable it on systems that
    need it.
ChangeLog
lib/fuse.c
test/test.c