You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

pwd_plan9.go 430B

123456789101112131415161718192021222324
  1. // Copyright 2015 The Go Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style
  3. // license that can be found in the LICENSE file.
  4. //go:build !go1.5
  5. // +build !go1.5
  6. package plan9
  7. func fixwd() {
  8. }
  9. func Getwd() (wd string, err error) {
  10. fd, err := open(".", O_RDONLY)
  11. if err != nil {
  12. return "", err
  13. }
  14. defer Close(fd)
  15. return Fd2path(fd)
  16. }
  17. func Chdir(path string) error {
  18. return chdir(path)
  19. }