summaryrefslogtreecommitdiff
path: root/internal/file
diff options
context:
space:
mode:
authorPaul Buetow <paul@buetow.org>2025-07-11 15:10:01 +0300
committerPaul Buetow <paul@buetow.org>2025-07-11 15:10:01 +0300
commit41540f7431d95256d889e0388a114dc1c1114f89 (patch)
tree0753f127c2955e2a1fdb9f5de630897aacf75f87 /internal/file
parent7ea46c38d44307f9d638e197b9b888df9bdd2c8a (diff)
fix the fctnl F_SET bug
Diffstat (limited to 'internal/file')
-rw-r--r--internal/file/file.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/internal/file/file.go b/internal/file/file.go
index 330ba21..d46e6db 100644
--- a/internal/file/file.go
+++ b/internal/file/file.go
@@ -99,6 +99,10 @@ func (f FdFile) Flags() Flags {
return f.flags
}
+func (f *FdFile) SetFlags(flags int32) {
+ f.flags = Flags(flags)
+}
+
func (f *FdFile) AddFlags(flags int32) {
f.flags = Flags(int32(f.flags) | flags)
}