mirror of
https://github.com/netbirdio/gvisor.git
synced 2026-05-22 17:12:49 -07:00
Deduplicate unix socket Release() method.
PiperOrigin-RevId: 308932254
This commit is contained in:
@@ -103,7 +103,7 @@ func (s *socketOpsCommon) DecRef() {
|
||||
}
|
||||
|
||||
// Release implemements fs.FileOperations.Release.
|
||||
func (s *SocketOperations) Release() {
|
||||
func (s *socketOpsCommon) Release() {
|
||||
// Release only decrements a reference on s because s may be referenced in
|
||||
// the abstract socket namespace.
|
||||
s.DecRef()
|
||||
|
||||
@@ -273,13 +273,6 @@ func (s *SocketVFS2) Write(ctx context.Context, src usermem.IOSequence, opts vfs
|
||||
})
|
||||
}
|
||||
|
||||
// Release implements vfs.FileDescriptionImpl.
|
||||
func (s *SocketVFS2) Release() {
|
||||
// Release only decrements a reference on s because s may be referenced in
|
||||
// the abstract socket namespace.
|
||||
s.DecRef()
|
||||
}
|
||||
|
||||
// Readiness implements waiter.Waitable.Readiness.
|
||||
func (s *SocketVFS2) Readiness(mask waiter.EventMask) waiter.EventMask {
|
||||
return s.socketOpsCommon.Readiness(mask)
|
||||
|
||||
Reference in New Issue
Block a user