|
|
|
|||||
|
NullHandleException
Hi,
I've downloaded and installed Ice on Linux (LFS 4) without any obvious problems. I've tried building the Printer example from the docs. Compiles and links OK. When I try to run the server or client I get an exception: ../../include/IceUtil/Handle.h:44 IceUtil::NullHandleException thrown in ic = Ice::initialize(argc,argv) Running make test fails in test/Ice/exceptions, testing checked cast. Any suggestions as to what might be wrong? I've probably missed something obvious so prepared to be embarrassed! Mike |
|
|||||
|
Mark,
I'm using gcc 3.2, xerces-c++ 2.1.0, OpenSSL 0.9.6, e2fsprogs 1.27, bzip2 1.0.2, Berkeley DB 4.1.25. Are there any others I need to check? Putting in some print statements, I end up in DefaultsAndOverrides.cpp getProperty("Ice.Default.Host") succeeds defaultHost.empty() is true, if-block entered. const_cast<string&>(defaultHost) =getLocalHost(true); fails Does this help? Mike |
|
||||||
|
Quote:
Quote:
- Mark |
|
||||||
|
Sorry Mike, there's an easier way to diagnose a NullHandleException: set the property Ice.NullHandleAbort=1 and the program will abort when the exception is created, leaving a core file from which you can obtain a stack trace.
- Mark |
|
|||||
|
I didn't see your suggestion in time but I've got some more information anyway:
In Network.cpp, IceInternal::getLocalHost(bool numeric) gethostbyname() returns 0 (the machine doesn't have a DNS entry so I guess this could be the source of the problem) This results in the exception: Network.cpp:646: Ice: NSException:DNS error: temporary error, try again Following the exception back up we go through: DefaultsAndOverrides.cpp - no try...catch Instance.cpp, IceInternal::Instance::Instance(...) Network.cpp:646: Ice: NSException:DNS error: temporary error, try again CommunicatorI.cpp, Ice::CommunicatorI::CommunicatorI(...) ../../include/IceUtil/Handle.h:44: IceUtil::NullHandleException Initialize.cpp, Ice::initialize(...) - no try...catch Server.cpp ../../include/IceUtil/Handle.h:44: IceUtil::NullHandleException Does this explain what's going on? Mike |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Operator Error - NullHandleException | eric.hill | Help Center | 3 | 07-19-2006 06:10 PM |