delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2003/02/24/04:58:05

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
To: cygwin AT cygwin DOT com
Subject: Re: to use dup() in cygwin
MIME-Version: 1.0
Message-ID: <OFF915C6D6.7B20FFA0-ONC1256CD7.0036A3C4@madrid.jazztel.com>
From: Fernando DOT Frutos DOT Martin AT es DOT jazztel DOT com
Date: Mon, 24 Feb 2003 10:58:17 +0100

Fernando DOT Frutos DOT Martin AT es DOT jazztel DOT com wrote:

> /*close the display exit and send it to the socket*/
>     close(1);
>     iError=dup(iDescSock);

Shouldn't you be using dup2() for this? It's time to step into the 1990s
here, methinks..
--
Shankar.


I use dup2 and it happens the same.


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019