Hi everyone,
I was just running tests of ICE using MSVS 2010 C++ express, now, I did everything, changed from /lib to /lib/vc100 and everything, but some weird things happen.
First, when I run it as debug with iced and iceutild, I get an error saying "The inferior stopped because it triggered an exception" and the disassembler code shows Memory access error, and the debugger shows write access violation.
Now, I used MSVC2008 with the normal libraries and had no issues, I even used MSVS 2010 professional and it worked with /lib/vc100, but now that I use express I get this issue.
When I build it as release instead of debug, the program actually runs, but when running I get the message: ObjectAdapterI.cpp:1215: Ice::EndpointParseException: error while parsing endpoint `invalid object adapter endpoint `
Now, from what I know the error is using createObjectAdapterWithEndpoints, I searched the forum, and it happened with MSVC2010 when not using the vc100 build, but I am using it, and still, I'm not able to debug and on release I get the Endpoint exception, here's the code, I'm sure it works because I tested with MSVC2010 professional and MSVC2008, and no, I don't use MSVC2010 pro anymore because it was just the trial, so developing with it is not an option.
Any ideas? thanks for your time everyone!Code://the main handler of the Ice runtime Ice::CommunicatorPtr ic; try { //initialize the Ice runtime ic = Ice::initialize(argc, argv); cout << "initialize the Ice runtime" << endl; //create the servant of Printer and add the runtime to the servant so it can be deleted on aboutToQuit() PrinterI *p = new PrinterI(); Ice::ObjectPtr object = p; cout << "create the servant of Printer" << endl; //create the object adapter, here's where it throws the exception Ice::ObjectAdapterPtr adapter = ic->createObjectAdapterWithEndpoints("SimplePrinterAdapter", "default -p 10000"); cout << "create the object adapter" << endl; //inform the object adapter of the printer servant and set an identity for the servant adapter->add(object, ic->stringToIdentity("SimplePrinter")); cout << "inform the object adapter of the printer servant and set an identity for the servant" << endl; //activate the adapter adapter->activate(); cout << "activate the adapter" << endl; } //catch any Ice initialization exception catch (const Ice::Exception& e) { //Ice::Exception.what() cout << "Error: " << e.what() << endl; }

Reply With Quote
