If you want this behavior you'll need to use the lower level methods in the os package <https://golang.org/pkg/os/#File.Readdirnames>.

    Regards
    Steve

On 19/07/2019 11:54, rob wrote:
I have this in my code

  files, err := ioutil.ReadDir(CleanDirName)

  if err != nil {

    log.Println(err)

  }

Occasionally I have a symlink to another computer that goes stale, with this error:

  lstat [symlinkname] stale NFS file handle

When this happens, ReadDir does not return any other files in the slice.  I would like it to.  Is there any way for me to get it to do that?

--rob solomon


--
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/de4ad0cc-f0d2-80bc-af11-fe2e51b41e74%40multiplay.co.uk.

Reply via email to