Skip to content

[BUG] Server crash when deleting symlinks pointing to a non-existing location #10

@1ras

Description

@1ras

Thanks for providing NetMount, this is a fantastic project!

During testing of symbolic links on the Linux server, I found the following issue:

Linux server (version 1.6.0):
ln -s test1 test2

DOS client ( version 1.7.0):
del test2

Linux server result:
CRITICAL Exception: get_dos_attrs_from_extended: Failed to fetch attributes of "/srv/dos/s-share/test2": No such file or directory

Which is true since the symlink points to a non-existing location, but I guess there should be some error handling.

The file size, date and time returned for the symlink that points to a non-existing location is also strange. It seems it's inherited from another file in the same directory.

The question is how best to handle symlinks pointing to a non-existing location on an OS that does not support symlinks. As all other functions I tested work fine with symlinks, maybe display non-existing ones as a 0-byte file with a date of January 1, 1980 (the oldest date DOS supports)?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions