From: Lennart Borgman <lennart.borgman.073@student.lu.se>
Cc: help-gnu-emacs@gnu.org, Emacs Devel <emacs-devel@gnu.org>
Subject: Re: asynchronous process management on WinWP; buffering problem?
Date: Sat, 15 Apr 2006 17:26:54 +0200 [thread overview]
Message-ID: <444110BE.3050009@student.lu.se> (raw)
In-Reply-To: <u8xq7jizt.fsf@jasonrumney.net>
Jason Rumney wrote:
> Lennart Borgman <lennart.borgman.073@student.lu.se> writes:
>
>
>> Can Emacs then tell _isatty that it is a terminal? Or what does Emacs
>> do to handle this?
>>
>>
>> Note: It looks like the POSIX name now is _isatty.
>>
>
> Probably not on Windows, since windows isn't POSIX and any POSIX layer
> that MingW32 has is unlikely to add functionality that is not already
> possible through other Windows APIs. On Windows stdout uses completely
> different API calls than console I/O.
>
It actually seems like is _isatty is defined in MinGW. I just tested a
small program I found here:
http://permalink.gmane.org/gmane.comp.gnu.mingw.msys/448
#include <stdio.h>
int main(int argc, char *argv[])
{
if (isatty(fileno(stdin)) && _isatty(fileno(stdout)))
printf("interactive\n");
else
printf("batch\n");
return 0;
}
If I run this program in cmd.exe it says "interactive". I get the same
result under MSYS and Cygwin. However running it in Emacs in shell:
M-x shell
it instead says "batch". (This is in the CVS version of Emacs.) Is this
what is expected?
next parent reply other threads:[~2006-04-15 15:26 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <10m877fael0h3.1kg7y6ljn4qmb$.dlg@40tude.net>
[not found] ` <443fdf5c$1@kcnews01>
[not found] ` <mailman.414.1145041920.9609.help-gnu-emacs@gnu.org>
[not found] ` <877j5r3ogd.fsf@catnip.gol.com>
[not found] ` <mailman.434.1145085136.9609.help-gnu-emacs@gnu.org>
[not found] ` <u8xq7jizt.fsf@jasonrumney.net>
2006-04-15 15:26 ` Lennart Borgman [this message]
2006-04-15 17:54 ` asynchronous process management on WinWP; buffering problem? Benjamin Riefenstahl
2006-04-15 23:50 ` Lennart Borgman
2006-04-17 13:08 ` Benjamin Riefenstahl
2006-04-17 16:02 ` Lennart Borgman
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=444110BE.3050009@student.lu.se \
--to=lennart.borgman.073@student.lu.se \
--cc=emacs-devel@gnu.org \
--cc=help-gnu-emacs@gnu.org \
/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.savannah.gnu.org/cgit/emacs.git
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 read-only IMAP folder(s) and NNTP newsgroup(s).