Skip to content

Commit

Permalink
chore: wip
Browse files Browse the repository at this point in the history
  • Loading branch information
nixpig committed Dec 24, 2024
1 parent 6550de0 commit cb6cd22
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 8 deletions.
1 change: 0 additions & 1 deletion container/container_init.go
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,6 @@ func (c *Container) Init(reexecCmd string, reexecArgs []string) error {
})
}

// FIXME: why does this segfault??
if ns.Type == specs.TimeNamespace {
if c.Spec.Linux.TimeOffsets != nil {
var tos bytes.Buffer
Expand Down
13 changes: 6 additions & 7 deletions container/container_reexec.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import (
"github.com/nixpig/brownie/filesystem"
"github.com/nixpig/brownie/iopriority"
"github.com/nixpig/brownie/scheduler"
"github.com/nixpig/brownie/sysctl"
"github.com/nixpig/brownie/terminal"
"github.com/opencontainers/runtime-spec/specs-go"
"golang.org/x/sys/unix"
Expand Down Expand Up @@ -117,12 +118,11 @@ func (c *Container) Reexec() error {
return err
}

// FIXME: why does this segfault??
// if c.Spec.Linux.Sysctl != nil {
// if err := sysctl.SetSysctl(c.Spec.Linux.Sysctl); err != nil {
// return fmt.Errorf("set sysctl: %w", err)
// }
// }
if c.Spec.Linux.Sysctl != nil {
if err := sysctl.SetSysctl(c.Spec.Linux.Sysctl); err != nil {
return fmt.Errorf("set sysctl: %w", err)
}
}

if err := filesystem.MountMaskedPaths(
c.Spec.Linux.MaskedPaths,
Expand Down Expand Up @@ -206,7 +206,6 @@ func (c *Container) Reexec() error {
}
}

// FIXME: why does this segfault??
if c.Spec.Process.IOPriority != nil {
if err := iopriority.SetIOPriority(*c.Spec.Process.IOPriority); err != nil {
return fmt.Errorf("set iop: %w", err)
Expand Down

0 comments on commit cb6cd22

Please sign in to comment.