Skip navigation.
 
mlNSSocketPortNameServer
FROM : Tobias Peciva
DATE : Fri Jan 04 03:12:43 2008

Hey List,

We're seeing some interesting NSSocketPortNameServer behavior in 10.5 
- so wondering if anyone else has come across this. There are two 
issues...

First, customers report that on some machines, the following call 
fails (i.e. returns NO):
[[NSSocketPortNameServer sharedInstance] registerPort:port 
name:@"unique.name.goes.here"]

According to the dox, this would only happen if another port is 
registered with the same name - but this does not appear to be the 
case, because calling portForName: yields nothing, and 
removePortForName: also fails. I have also confirmed that the port 
passed in is non-nil and valid. Interestingly enough, the problem only 
started appearing on Intel iMacs after one of the software updates in 
mid-December. Everything works fine on PowerPC Macs and non-iMac Intel 
machines.

Second, I may have misunderstood how NSSocketPortNameServer works, but 
I created two test applications that create one socket port each 
(different port numbers, obviously), then attempt to register these 
ports with the same name. The NSPortNameServer dox suggest that the 
second app should fail to register its port, because another port has 
already been registered with the same name. But in actual fact, both 
ports are successfully registered with the same name.

So, bugs or features? What am I missing? Any ideas?

Thanks muchly!

Peace,
Tobias

--
Tobias Peciva
Team Leader / Software Architect
Pharos Systems - http://www.pharos.com/

Related mailsAuthorDate
mlNSSocketPortNameServer Tobias Peciva Jan 4, 03:12
mlRe: NSSocketPortNameServer Scott Stevenson Jan 10, 08:35