Fix stat/lstat error checking in a few places.

closes #6929. Please review.
That’s a very good point. Let me review this code over the weekend and I’ll reply then.

-Erik

> On Jul 11, 2014, at 2:37 PM, Tibor Vass <notifications@github.com> wrote:
> 
> In utils/utils.go:
> 
> > @@ -889,8 +889,8 @@ func ValidateContextDirectory(srcPath string) error {
> >  			return err
> >  		}
> >  		// skip checking if symlinks point to non-existing files, such symlinks can be useful
> > -		lstat, _ := os.Lstat(filePath)
> > -		if lstat.Mode()&os.ModeSymlink == os.ModeSymlink {
> > +		lstat, err := os.Lstat(filePath)
> @erikh well since we error out anyway if it's a symlink, why do we care about whether the symlink points to an existing file or not? I think we could remove the Stat (from lines 887 to 890), and just use Lstat.
> 
> —
> Reply to this email directly or view it on GitHub.
>