From: "Andrej Borsenkow" <Andrej.Borsenkow@mow.siemens.ru>
To: "ZSH workers mailing list" <zsh-workers@sunsite.auc.dk>
Subject: Questions about zpty module.
Date: Fri, 3 Mar 2000 17:28:58 +0300 [thread overview]
Message-ID: <000601bf851c$cff2af30$21c9ca95@mow.siemens.ru> (raw)
- does zsh reads pty output line by line? Or does it just reads what happens
to be in buffer? How is it related to blocking/non-blocking modes?
- manual says:
The -r option can be used to read the output of the command NAME.
Without a PARAM argument, the string read will be printed to
standard output. With a PARAM argument, the string read will be
put in the parameter named PARAM. If the PATTERN is also given,
output will be read until the whole string read matches the
PATTERN.
what is exactly mentioned "string" that is matched against PATTERN? Is it
the whole input? That is, in case
zpty -r command var '*\n'
will zsh wait until it reads the whole line? What happens in case of
non-blocking read then? In this case read can return with only part of
input.
- is it possible to know, if write was successful (or how many characters
were actually written)? In case of non-blocking fd and full pipe write() can
return with only partial buffer (or none at all) written
- what about read/write with timeout? It can avoid problems with
non-blocking mode while providing safe way to detect external program
failure.
/andrej
next reply other threads:[~2000-03-03 14:29 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2000-03-03 14:28 Andrej Borsenkow [this message]
2000-03-04 6:19 ` Bart Schaefer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='000601bf851c$cff2af30$21c9ca95@mow.siemens.ru' \
--to=andrej.borsenkow@mow.siemens.ru \
--cc=zsh-workers@sunsite.auc.dk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).