mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
runtime: rename close to closefd
Avoids shadowing the builtin channel close function. Change-Id: I7a729b0937c8248fe27222be61318a88db995eee Reviewed-on: https://go-review.googlesource.com/8898 Reviewed-by: Ian Lance Taylor <iant@golang.org> Run-TryBot: David Crawshaw <crawshaw@golang.org>
This commit is contained in:
parent
2f98bac310
commit
cea272de30
37 changed files with 42 additions and 42 deletions
|
|
@ -133,7 +133,7 @@ var urandom_dev = []byte("/dev/urandom\x00")
|
|||
func getRandomData(r []byte) {
|
||||
fd := open(&urandom_dev[0], 0 /* O_RDONLY */, 0)
|
||||
n := read(fd, unsafe.Pointer(&r[0]), int32(len(r)))
|
||||
close(fd)
|
||||
closefd(fd)
|
||||
extendRandom(r, int(n))
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue