[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Q] GSFileHandle in Win32

From: Richard Frith-Macdonald
Subject: Re: [Q] GSFileHandle in Win32
Date: Thu, 10 Jul 2003 08:24:49 +0100

On Tuesday, July 8, 2003, at 05:24 AM, S.J.Chun wrote:


After successful compilation and load of XMLRPC framework, I've found NSFileHandle, actually GSFileHandle implementation problem in Win32. XMLRPC/EDCommon uses initWithNativeHandle: of NSFileHandle with SOCKET handle. The problem is GSFileHandle changes SOCKET to int with _open_osfhandle but send, recv, ioctlsocket like calls need SOCKET, not int descriptor. In POSIX case, this won't be the problem, because descriptor and
socket is the same data type. Can you help me? Thank you in advance.

While the exact problem is not clear to me, I think you might need to add an instance variable to say what type of handle you have, and use that ivar to decide to convert from one to another where you need to pass the handle/descriptor to functions which don't deal with the other type. So, you would only use _open_osfhandle at the point where it's needed, rather than at initialisation.

I'll happily look at any patch you have.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]