www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/02/28/03:49:06

Date: Mon, 28 Feb 2000 08:41:26 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
X-Sender: eliz AT is
To: Ken Yap <ken_yap AT my-deja DOT com>
cc: djgpp AT delorie DOT com
Subject: Re: why isn't the FSEXT hook implemented for dup in 2.03?
In-Reply-To: <NGDPIMGFFIHBBCAA@my-deja.com>
Message-ID: <Pine.SUN.3.91.1000228084053.8833K-100000@is>
MIME-Version: 1.0
Reply-To: djgpp AT delorie DOT com
Errors-To: dj-admin AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On Sun, 27 Feb 2000, Ken Yap wrote:

> >> ftprchan = fdopen(fd, "rb");
> >> ftpwchan = fdopen(dup(fd), "wb");
> >
> >I don't understand why the normal dup won't do in this case.  You
> >*can* call dup and dup2 on the handle returned by the FSEXT, because
> >it's a valid DOS handle.  And since you hooked _open, the new handle
> >gets hooked inside that handler, right?  So where is the problem?
> 
> The problem is the WATT-32 dup needs to be called to do the right thing
> for a socket dup

What is ``the right thing for a socket dup''?

I'm asking because I think most (if not all) of what needs to be done
is already done by the existing functionality if you simply call dup.

> >I'm sure your patches to add this would be greatly appreciated ;-).
> 
> If I can figure out what's going on.

Assuming you took a glance at the FSEXT implementation in the library
sources, feel free to ask questions here if you find something
unclear.

- Raw text -


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