Re: A _fde Struct change proposal

From: Guido Serassio <serassio@dont-contact.us>
Date: Tue, 01 Oct 2002 12:45:06 +0200

Hi Adrian,

At 06.33 01/10/2002, Adrian Chadd wrote:
>On Sat, Sep 28, 2002, Robert Collins wrote:
> > On Sat, 2002-09-28 at 20:17, Guido Serassio wrote:
> > > Hi,
> > >
> > > Working on Windows port, I have found that my work can be helped
> adding to
> > > _fde structure a FD_CLOSE_METHOD function pointer like FD_READ_METHOD
> and
> > > FD_WRITE_METHOD, and use it instead of close().
> > >
> > > What are Your opinions ?
> >
> > Do it. This could even go into HEAD now, IMO.
> >
> > However, Adrian's current commloops work may have some impact.
> >
> > Adrian?
> >
>
>You should be using comm_close/file_close()/whatever, rather than a direct
>call to close(). Any direct calls to close() are bogus.
>
>Now, why do you want to add an FD_CLOSE_METHOD?

On Windows close() doesn't close sockets, so on comm.c and in other places,
close() can't be used. FD_CLOSE_METHOD should be the low level function
used from comm_close/file_close().

The same thing is true for read() and write(), and FD_READ_METHOD and
FD_WRITE_METHOD was very useful when porting HEAD to Windows.

Now I'm trying a possible implementation of FD_CLOSE_METHOD on nt branch,
but at this time I'm still evaluating the benefits, if any.

Regards

Guido

>Adrian

-
=======================================================
Serassio Guido
Via Albenga, 11/4 10134 - Torino - ITALY
E-mail: guido.serassio@serassio.it
WWW: http://www.serassio.it
Received on Tue Oct 01 2002 - 04:45:14 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:16:50 MST