From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Victor Kirk Newsgroups: gmane.emacs.help Subject: RE: Re[2]: get stdout/stderr while running a program Date: Fri, 29 Nov 2002 10:34:11 -0000 Sender: help-gnu-emacs-admin@gnu.org Message-ID: <195F58F118C9D311B622009027DC812FFDD8B0@mail1.technology.serco.com> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" X-Trace: main.gmane.org 1038565902 14067 80.91.224.249 (29 Nov 2002 10:31:42 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Fri, 29 Nov 2002 10:31:42 +0000 (UTC) Cc: help-gnu-emacs@gnu.org Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 18HiQt-0003eY-00 for ; Fri, 29 Nov 2002 11:31:39 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10) id 18HiOv-0007Zo-00; Fri, 29 Nov 2002 05:29:37 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.10) id 18HiOK-0006UY-00 for help-gnu-emacs@gnu.org; Fri, 29 Nov 2002 05:29:00 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10) id 18HiOJ-0006UH-00 for help-gnu-emacs@gnu.org; Fri, 29 Nov 2002 05:29:00 -0500 Original-Received: from porky.serco.com ([195.50.81.243]) by monty-python.gnu.org with esmtp (Exim 4.10) id 18HiOI-0006UD-00 for help-gnu-emacs@gnu.org; Fri, 29 Nov 2002 05:28:58 -0500 Original-Received: from [10.22.1.247] (helo=mail1.technology.serco.com) by porky.serco.com with esmtp (Exim 4.10) id 18HiOI-0006Hy-01; Fri, 29 Nov 2002 10:28:58 +0000 Original-Received: by mail1.technology.serco.com with Internet Mail Service (5.5.2650.21) id ; Fri, 29 Nov 2002 10:34:12 -0000 Original-To: 'Nagash' X-Mailer: Internet Mail Service (5.5.2650.21) X-Scanner: exiscan for exim4 (http://duncanthrax.net/exiscan/) *18HiOI-0006Hy-01*VVVpJ8LtbDI* Errors-To: help-gnu-emacs-admin@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.0.11 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.emacs.help:4142 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:4142 Assuming there is not a probelm with emacs. presumably other programs work fine under the shell. > a little example: > /* c-code */ > printf("my output"); > /* "my output" now visible in the shell */ stdout is buffered, so this is only output when the buffer is full. What happens if you explicity flush the output by printf("my output"); fflush(stdout); > exit(0); > /* "my output" now visible in my emacs buffer */ This would cause the file buffer to be flushed to the output. > its a little bit exhausting to switch always between a shell > and emacs. it interrupts my working flow. Quite right. One of the most useful things about running a shell under emacs is you can search through the program's output This message, including attachments, is intended only for the use by the person(s) to whom it is addressed. It may contain information which is privileged and confidential. Copying or use by anybody else is not authorised. If you are not the intended recipient, please contact the sender as soon as possible. The views expressed in this communication may not necessarily be the views held by Serco Integrated Transport.