2004-04-14 Pierre Humblet <pierre.humblet@ieee.org>

* path.h (path_conv::set_symlink): Add argument.
        (path_conv::get_symlink_length): New method.
        (path_conv::symlink_length): New member.
        * path.cc (path_conv::check): Pass symlen to set_symlink.
        * fhandler_disk_file.cc (fhandler_base::fstat_helper): For symlinks
        set st_size from get_symlink_length.
This commit is contained in:
Pierre Humblet
2004-04-14 03:08:00 +00:00
parent 3614afe6a0
commit b923181eca
4 changed files with 14 additions and 2 deletions

View File

@ -705,7 +705,7 @@ path_conv::check (const char *src, unsigned opt,
saw_symlinks = 1;
if (component == 0 && !need_directory && !(opt & PC_SYM_FOLLOW))
{
set_symlink (); // last component of path is a symlink.
set_symlink (symlen); // last component of path is a symlink.
if (opt & PC_SYM_CONTENTS)
{
strcpy (path, sym.contents);