Ejemplo n.º 1
0
func (c *ContainerInit) GetPtyMaster(arg struct{}, fd *fdrpc.FD) error {
	c.mtx.Lock()
	defer c.mtx.Unlock()

	if c.ptyMaster == nil {
		return errors.New("no pty in this container")
	}
	fd.FD = int(c.ptyMaster.Fd())

	return nil
}
Ejemplo n.º 2
0
func (o *Obj) GetStdOut(a struct{}, b *fdrpc.FD) error {
	fmt.Println("GetStdOut")
	b.FD = 1
	return nil
}