Skip to content
This repository has been archived by the owner on May 18, 2024. It is now read-only.

Commit

Permalink
getcwd for windows
Browse files Browse the repository at this point in the history
  • Loading branch information
xushiwei committed Aug 9, 2022
1 parent c1f54a3 commit 2366f38
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions z_unistd_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,7 @@ func Getcwd(buf *int8, size uint64) *int8 {
setErrno(e)
return nil
}
return string(utf16.Decode(b[0:n])), nil
return buf
return fromUtf8(buf, size, b[0:n])
}

// TODO: can be faster
Expand Down

0 comments on commit 2366f38

Please sign in to comment.