symlink: nfs41_symlink_follow() for readdir and open

added nfs41_file_info.symlink_dir to replace readdir's info.cansettime hack.  when nfs_file_info_to_attributes() finds info.type==NF4LNK, it adds the FILE_ATTRIBUTE_DIRECTORY flag if info.symlink_dir is set

renamed nfs41_symlink_follow() to nfs41_symlink_target()
generalized lookup_symlink() into nfs41_symlink_follow(), which is called by readdir and open (also avoids an extra lookup)

added queries for symlink target type when doing normal GETATTRs (getattr.c) and opens with OPEN_REPARSE_POINT set (open.c)

Signed-off-by: Casey Bodley <cbodley@citi.umich.edu>
This commit is contained in:
Casey Bodley 2010-10-14 15:20:45 -04:00 committed by unknown
parent a8f66804d5
commit eb9d9bbd4c
7 changed files with 80 additions and 36 deletions

View file

@ -184,6 +184,7 @@ typedef struct __nfs41_file_info {
bool_t cansettime; /* XXX: per-fs */
bool_t case_insensitive;
bool_t case_preserving;
bool_t symlink_dir;
} nfs41_file_info;
#endif /* !__NFS41_DAEMON_TYPES_H__ */