From 1c3761bb53c95d75751f95e8f77d9d1e5928b968 Mon Sep 17 00:00:00 2001 From: Ophestra Date: Tue, 25 Aug 2026 14:48:27 +0900 Subject: container: enter init path early There is generally no use case where any setup is required before init, and requiring the explicit function call is error-prone and unnecessary. It also causes trouble with packages using a similar trick. This change moves argv0 check early and makes it an import side effect. The stub will be removed in v0.5. Signed-off-by: Ophestra --- container/initplace.go | 3 --- 1 file changed, 3 deletions(-) (limited to 'container/initplace.go') diff --git a/container/initplace.go b/container/initplace.go index ab477139..4993d0b3 100644 --- a/container/initplace.go +++ b/container/initplace.go @@ -1,7 +1,6 @@ package container import ( - "encoding/gob" "fmt" "syscall" @@ -14,8 +13,6 @@ const ( intermediatePatternTmpfile = "tmp.*" ) -func init() { gob.Register(new(TmpfileOp)) } - // Place is a helper for appending [TmpfileOp] to [Ops]. func (f *Ops) Place(name *check.Absolute, data []byte) *Ops { *f = append(*f, &TmpfileOp{name, data}) -- cgit v1.3.1