The trouble with symbolic links
The trouble with symbolic links
Posted Jul 9, 2022 3:31 UTC (Sat) by Subsentient (guest, #142918)Parent article: The trouble with symbolic links
I personally don't *want* most userspace programs to be able to tell if something is a link. I've much more often had issues with a program that saw a symlink and refused to dereference it, than I ever have with a program that used them implicitly.
Note to other userspace developers: Please use stat() instead of lstat() whenever possible. You don't know if there's a good reason it's a symlink, for example, a .config folder could be pointing into an sshfs network drive so my settings are synced between machines. I put symlinks in weird places if I think they're useful, and the only times it hurts me are when some application is using lstat() and/or looking for symlinks some other way.
