Opened 3 years ago

Closed 3 years ago

Last modified 3 years ago

#5482 closed bug (worksforme)

isSymbolicLink doesn't work

Reported by: DmitryBespalov Owned by:
Priority: normal Milestone:
Component: libraries/unix Version: 7.2.1
Keywords: isSymbolicLink Cc:
Operating System: Linux Architecture: x86_64 (amd64)
Type of failure: None/Unknown Difficulty:
Test Case: Blocked By:
Blocking: Related Tickets:

Description

This function from System.Posix.Files (unix-2.5.0.0) always returns False for symlinks on my linux os (2.6.39-gentoo-r3). GHC version 7.0.4. What's wrong?

Change History (3)

comment:1 Changed 3 years ago by igloo

  • Resolution set to worksforme
  • Status changed from new to closed

I suspect you're using getFileStatus rather than getSymbolicLinkStatus. If not, please reopen and give a complete testcase.

comment:2 Changed 3 years ago by daniel.is.fischer

Perhaps the docs for getFileStatus should mention that symbolic links are followed, not everybody knows that (I use stat rarely enough to forget it and only remember when I get unexpected results).

comment:3 Changed 3 years ago by DmitryBespalov

Thank you, indeed I was used getFileStatus. But Daniel right, it would be nice to mention this feature in description of getFileStatus.

Note: See TracTickets for help on using tickets.