[omniORB] OmniORB 4.1 on Mac OS X - problem with bind()

Peter Chase peter.chase at globalgraphics.com
Wed Jun 13 11:49:46 BST 2007


At 13/06/2007 10:43:05, Duncan Grisby <duncan at grisby.org> wrote:
>On Thursday 7 June, "Peter Chase" wrote:
>
>> We are transitioning from OmniORB 3.0.4 to 4.1 are having problems
>> starting OmniORB 4.1 on Mac OS X. It starts OK on Windows (XP and Vista
>> tested) and Linux.
>>
>> The problem occurs after ORB initialisation, when we try to find the 
root
>> POA. Inside OmniORB, it is failing to bind().
>>
>> Error message from OmniORB: -
>>         Error: Unable to create an endpoint of this description:
>> giop:tcp:172.16.153.81:9907
>
>Are you sure that's the right IP address, and that nothing else is
>listening on that port?  What happens if you don't give an endPoint
>option?

Yes, that is very definitely the right IP address. We have additionally 
tried 127.0.0.1, which fails similarly.

>What output do you get if you run with -ORBtraceLevel 25?

Not a lot.

At the moment, there is a possible explanation. The boss's superior 
Googling skills found the following article: -

http://www.digitalmars.com/d/archives/digitalmars/D/bugs/Issue_818_New_std.socket.InternetAddress.sin_needs_to_be_properly_initialized_on_OS_X_9912.html

Some quick tests have indicated that our problem is due to this. By 
zeroing-out the struct sockaddr_in inside IP4AddrInfo constructor, the 
problem seems to go away (in a quick test - to be confirmed). It looks as 
if I may need to define HAVE_STRUCT_SOCKADDR_IN_SIN_LEN and 
HAVE_STRUCT_SOCKADDR_IN_SIN_ZERO in "omniORB4:CORBA_sysdep_trad.h" for 
"__darwin__".

Note that I'm using our own platform file ("uni_macos....mk") because 
we're building Universal Binary. Maybe a build done with "configure" would 
have detected the need for these symbols.

I shall reply to the thread to let you know whether the above suggested 
root cause and fix are correct.



More information about the omniORB-list mailing list