code: func (e *localExec) Wait() (*ExecResult, error) {
  	if e.Cmd.Process == nil {
  		e.Ctx.Errorf("no process")
  	}
  
  	// wait for the command to complete, then figure out if the command
  	// successfully exited or if it exited in failure
  	execResult, err := collectLocalStatus(e.Cmd, e.Cmd.Wait())
  
  	// emit the result of execution to the audit log
  	emitExecAuditEvent(e.Ctx, e.GetCommand(), execResult, err)
  
  	return execResult, trace.Wrap(err)
  }
docs: // Wait will block while the command executes.