From 0e91d2e0e97820da5c56f2726e11f4bd9aa40af8 Mon Sep 17 00:00:00 2001 From: Cory Snider Date: Wed, 11 Jan 2023 20:10:09 -0500 Subject: libnetwork: return concrete-typed *Sandbox Basically every exported method which takes a libnetwork.Sandbox argument asserts that the value's concrete type is *sandbox. Passing any other implementation of the interface is a runtime error! This interface is a footgun, and clearly not necessary. Export and use the concrete type instead. Signed-off-by: Cory Snider --- daemon/rename.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'daemon/rename.go') diff --git a/daemon/rename.go b/daemon/rename.go index 55a2488529..4ecfa62257 100644 --- a/daemon/rename.go +++ b/daemon/rename.go @@ -16,7 +16,7 @@ import ( func (daemon *Daemon) ContainerRename(oldName, newName string) error { var ( sid string - sb libnetwork.Sandbox + sb *libnetwork.Sandbox ) if oldName == "" || newName == "" { -- cgit v1.2.1