mirror of
https://github.com/netbirdio/gvisor.git
synced 2026-05-22 17:12:49 -07:00
Plumb restore context to afterLoad()
This allows for external information to be passed to restore code, like host FDs to be remapped. Updates #1956 PiperOrigin-RevId: 612540749
This commit is contained in:
committed by
gVisor bot
parent
c6b06ab1a5
commit
c087777e37
@@ -15,11 +15,13 @@
|
||||
package netstack
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"gvisor.dev/gvisor/pkg/tcpip/stack"
|
||||
)
|
||||
|
||||
// afterLoad is invoked by stateify.
|
||||
func (s *Stack) afterLoad() {
|
||||
func (s *Stack) afterLoad(context.Context) {
|
||||
s.Stack = stack.StackFromEnv // FIXME(b/36201077)
|
||||
if s.Stack == nil {
|
||||
panic("can't restore without netstack/tcpip/stack.Stack")
|
||||
|
||||
Reference in New Issue
Block a user