mirror of
https://github.com/rwinkhart/sys.git
synced 2026-09-02 07:07:33 -04:00
unix: use Go 1.21+ clear built-in
Inspired by CL 698495. Change-Id: Ic6ff68a60d41b6ffb6a28f523597c5d36c1e4d2f Reviewed-on: https://go-review.googlesource.com/c/sys/+/704915 LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: Michael Knyszek <mknyszek@google.com> Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com> Reviewed-by: Sean Liao <sean@liao.dev> Reviewed-by: Mark Freeman <markfreeman@google.com>
This commit is contained in:
committed by
Tobias Klauser
parent
137f2eda35
commit
32e203842b
+1
-3
@@ -23,7 +23,5 @@ func (fds *FdSet) IsSet(fd int) bool {
|
||||
|
||||
// Zero clears the set fds.
|
||||
func (fds *FdSet) Zero() {
|
||||
for i := range fds.Bits {
|
||||
fds.Bits[i] = 0
|
||||
}
|
||||
clear(fds.Bits[:])
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user