diff options
| author | Ophestra <cat@gensokyo.uk> | 2026-03-11 20:03:08 +0900 |
|---|---|---|
| committer | Ophestra <cat@gensokyo.uk> | 2026-03-11 20:03:08 +0900 |
| commit | fd515badffc159b62c5140b8340164ccd29e41f5 (patch) | |
| tree | e4bfb24189960c360bd72e964d3f0acb3b28c4b7 /container/container.go | |
| parent | 330a344845aa8653772a9be6c085f4fdb602a028 (diff) | |
container: move scheduler policy constants to std
This avoids depending on cgo.
Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'container/container.go')
| -rw-r--r-- | container/container.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/container/container.go b/container/container.go index e7fd8cee..49b3cfe6 100644 --- a/container/container.go +++ b/container/container.go @@ -40,7 +40,7 @@ type ( AllowOrphan bool // Scheduling policy to set via sched_setscheduler(2). The zero value // skips this call. Supported policies are [SCHED_BATCH], [SCHED_IDLE]. - SchedPolicy SchedPolicy + SchedPolicy std.SchedPolicy // Cgroup fd, nil to disable. Cgroup *int // ExtraFiles passed through to initial process in the container, with @@ -373,7 +373,7 @@ func (p *Container) Start() error { // sched_setscheduler: thread-directed but acts on all processes // created from the calling thread - if p.SchedPolicy > 0 && p.SchedPolicy <= _SCHED_LAST { + if p.SchedPolicy > 0 && p.SchedPolicy <= std.SCHED_LAST { var param schedParam if priority, err := p.SchedPolicy.GetPriorityMin(); err != nil { return &StartError{ |
