]> Cypherpunks repositories - gostls13.git/commit
syscall: implement Ftruncate using a single syscall on Windows
authorqmuntal <quimmuntal@gmail.com>
Wed, 9 Oct 2024 08:12:57 +0000 (10:12 +0200)
committerQuim Muntal <quimmuntal@gmail.com>
Wed, 9 Oct 2024 17:22:48 +0000 (17:22 +0000)
commit0fd2d4d6c2101fb615a7546f49e92a2187191fb0
treec06315f53adc1827417333b48c28a883881fb505
parent3352db152b8347650e1fd3c9f26c335586577b21
syscall: implement Ftruncate using a single syscall on Windows

Ftruncate can be implemented on Windows using a single syscall. This
makes the implementation more efficient and less prone to races when
used in combination with other Seek calls.

Change-Id: I5d9f780fba2710403fce89d3325e519f33ad9ae8
Reviewed-on: https://go-review.googlesource.com/c/go/+/618835
Reviewed-by: Damien Neil <dneil@google.com>
Reviewed-by: Cherry Mui <cherryyz@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
src/syscall/syscall_windows.go
src/syscall/zsyscall_windows.go