gnustep-dev
[Top][All Lists]
Advanced

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

Problem in UnixFileHandle


From: Marcus Müller
Subject: Problem in UnixFileHandle
Date: Mon, 8 Apr 2002 03:43:20 +0200

Hi,

I just stumbled across this problem when finalizing the port of the ED* frameworks to GNUstep. If a UnixFileHandle is initialized with a fileDescriptor, neither acceptOK nor connectOK are set to YES. I understand that the GNUstep implementation of NSFileHandle offers a "richer" API to initialize it with Sockets (and indicating in what mode (client/server) they should be used) - however this behavior is incompatible with Apple's implementation. Although no "higher level" checking (as GNUstep introduces by inventing i.e acceptOK) can be guaranteed when setting acceptOK and friends by default to YES, it doesn't prevent the programmer from using the initWithFileDescriptor: method with a proper fileHandle. It also shouldn't break things because the GNUstep additions can implement stricter settings (as they do now).

So could one with access to the CVS add

      acceptOK = YES;
      connectOK = YES;

to the end of UnixFileHandle's - (id) initWithFileDescriptor: (int)desc closeOnDealloc: (BOOL)flag method?

Thanks,

  Marcus


P.S.: In case anybody is curious as to why I need that behaviour - EDInternet introduces a fairly sophisticated Socket abstraction on top of NSFileHandle (as opposed to other frameworks which usually implement their own hierarchy).

--
Marcus Mueller  .  .  .  crack-admin/coder ;-)
Mulle kybernetiK  .  http://www.mulle-kybernetik.com
Current projects: finger address@hidden




reply via email to

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