Re: [go-nuts] Possible bug on os.Stat and mode is symlink

2017-12-26 Thread Ian Lance Taylor
On Mon, Dec 25, 2017 at 1:48 AM, Shulhan wrote: > Environment > > OS: Linux xenom-bubu 4.14.8-1-ARCH #1 SMP PREEMPT Wed Dec 20 21:27:44 > UTC 2017 x86_64 GNU/Linux > > Go: go1.10beta1 linux/amd64 > > Steps to reproduce > > $ mkdir testSymlink > $ cd testSymlink > $ touch test > $ ln -s tes

[go-nuts] Possible bug on os.Stat and mode is symlink

2017-12-25 Thread Shulhan
Environment OS: Linux xenom-bubu 4.14.8-1-ARCH #1 SMP PREEMPT Wed Dec 20 21:27:44 UTC 2017 x86_64 GNU/Linux Go: go1.10beta1 linux/amd64 Steps to reproduce $ mkdir testSymlink $ cd testSymlink $ touch test $ ln -s test link $ cd .. $ test -L testSymlink/link # true, exit status 0

Re: [go-nuts] Possible bug on os.Stat and mode is symlink

2017-12-25 Thread Jakob Borg
You want os.Lstat. > On 25 Dec 2017, at 11:36, Shulhan wrote: > > Environment > > OS: Linux xenom-bubu 4.14.8-1-ARCH #1 SMP PREEMPT Wed Dec 20 21:27:44 > UTC 2017 x86_64 GNU/Linux > > Go: > - go1.10beta1 linux/amd64 > - go1.9.2 > > Steps to reproduce > > $ mkdir testSymlink > $ cd testSyml

[go-nuts] Possible bug on os.Stat and mode is symlink

2017-12-25 Thread Shulhan
Environment OS: Linux xenom-bubu 4.14.8-1-ARCH #1 SMP PREEMPT Wed Dec 20 21:27:44 UTC 2017 x86_64 GNU/Linux Go: - go1.10beta1 linux/amd64 - go1.9.2 Steps to reproduce $ mkdir testSymlink $ cd testSymlink $ touch test $ ln -s test link $ cd .. $ test -L testSymlink/link # true, exi