execstream: make Exit field a pointer again
To support serializing exit codes equal to 0.
This commit is contained in:
parent
8da34cbc06
commit
5686bb183c
|
|
@ -130,7 +130,7 @@ func (exec *Exec) Run(
|
|||
// Post an exit event
|
||||
exitFrame := &execstream.Frame{
|
||||
Type: execstream.FrameTypeExit,
|
||||
Exit: execstream.Exit{
|
||||
Exit: &execstream.Exit{
|
||||
Code: 0,
|
||||
},
|
||||
}
|
||||
|
|
|
|||
|
|
@ -20,12 +20,12 @@ const (
|
|||
type Frame struct {
|
||||
Type FrameType `json:"type"`
|
||||
Data []byte `json:"data,omitempty"`
|
||||
Exit Exit `json:"exit,omitempty"`
|
||||
Exit *Exit `json:"exit,omitempty"`
|
||||
Error string `json:"error,omitempty"`
|
||||
}
|
||||
|
||||
type Exit struct {
|
||||
Code int32 `json:"code,omitempty"`
|
||||
Code int32 `json:"code"`
|
||||
}
|
||||
|
||||
func WriteFrame(ctx context.Context, wsConn *websocket.Conn, frame *Frame) error {
|
||||
|
|
|
|||
Loading…
Reference in New Issue