summaryrefslogtreecommitdiffhomepage
path: root/pkg/refs_vfs2
diff options
context:
space:
mode:
authorDean Deng <deandeng@google.com>2020-08-17 11:40:08 -0700
committergVisor bot <gvisor-bot@google.com>2020-08-17 11:42:20 -0700
commit3bd066d5032c297e501f5c71be301ffa2fe9ed34 (patch)
treef689175cdbabf2ca52c76d111fafe0e3450f5a0c /pkg/refs_vfs2
parent58154194b3e472cf476be6bf0530bf271d1d29f8 (diff)
Remove weak references from unix sockets.
The abstract socket namespace no longer holds any references on sockets. Instead, TryIncRef() is used when a socket is being retrieved in BoundEndpoint(). Abstract sockets are now responsible for removing themselves from the namespace they are in, when they are destroyed. Updates #1486. PiperOrigin-RevId: 327064173
Diffstat (limited to 'pkg/refs_vfs2')
-rw-r--r--pkg/refs_vfs2/BUILD6
-rw-r--r--pkg/refs_vfs2/refs.go4
2 files changed, 4 insertions, 6 deletions
diff --git a/pkg/refs_vfs2/BUILD b/pkg/refs_vfs2/BUILD
index 7f180c7bd..7b3e10683 100644
--- a/pkg/refs_vfs2/BUILD
+++ b/pkg/refs_vfs2/BUILD
@@ -19,10 +19,8 @@ go_template(
)
go_library(
- name = "refs",
- srcs = [
- "refs.go",
- ],
+ name = "refs_vfs2",
+ srcs = ["refs.go"],
visibility = ["//pkg/sentry:internal"],
deps = ["//pkg/context"],
)
diff --git a/pkg/refs_vfs2/refs.go b/pkg/refs_vfs2/refs.go
index ee01b17b0..99a074e96 100644
--- a/pkg/refs_vfs2/refs.go
+++ b/pkg/refs_vfs2/refs.go
@@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
-// Package refs defines an interface for a reference-counted object.
-package refs
+// Package refs_vfs2 defines an interface for a reference-counted object.
+package refs_vfs2
import (
"gvisor.dev/gvisor/pkg/context"