code: func unlockpt(f *os.File) error {
  	var u int32
  	if _, _, err := unix.Syscall(unix.SYS_IOCTL, f.Fd(), unix.TIOCSPTLCK, uintptr(unsafe.Pointer(&u))); err != 0 {
  		return err
  	}
  	return nil
  }
docs: // unlockpt unlocks the slave pseudoterminal device corresponding to the master pseudoterminal referred to by f.
  // unlockpt should be called before opening the slave side of a pty.