libct: move cmsg helpers to new internal/cmsg package

These helpers all make more sense as a self-contained package and moving
them has the added benefit of removing an unneeded libpathrs dependency
(from libcontainer/utils's import of pathrs-lite) from several test
binaries.

Signed-off-by: Aleksa Sarai <aleksa@amutable.com>
This commit is contained in:
Aleksa Sarai
2026-04-07 19:47:57 +10:00
parent 80fc1cd34e
commit ca509e76ff
10 changed files with 63 additions and 20 deletions
+2 -2
View File
@@ -9,8 +9,8 @@ import (
"sync"
"github.com/containerd/console"
"github.com/opencontainers/runc/internal/cmsg"
"github.com/opencontainers/runc/libcontainer"
"github.com/opencontainers/runc/libcontainer/utils"
)
type tty struct {
@@ -100,7 +100,7 @@ func (t *tty) initHostConsole() error {
}
func (t *tty) recvtty(socket *os.File) (Err error) {
f, err := utils.RecvFile(socket)
f, err := cmsg.RecvFile(socket)
if err != nil {
return err
}