Archived
This forum has been archived. Please start a new discussion on GitHub.
Ice::Application within an IceUtil::Tthread
alfredt
in Help Center
I want to run Ice::Application within an IceUtil::Thread.
I get an exception when exiting the application.
I have included the MSVC7.1 project
Also if you break just before Thread::run exits you will see that the second argument of argv has been zeroed. Bug?
I realise that it is not the most effecient thread usage.
The reasoning is the fastest way to add Ice to an existing app.
Thanks
Alfred
I get an exception when exiting the application.
I have included the MSVC7.1 project
Also if you break just before Thread::run exits you will see that the second argument of argv has been zeroed. Bug?
I realise that it is not the most effecient thread usage.
The reasoning is the fastest way to add Ice to an existing app.
Thanks
Alfred
0
Comments
-
Have a look at this:
app.main(1, argv, "Ice.config");
You are telling main that argv has only one element, not two elements.
It should be:
app.main(2, argv, "Ice.config");
By the way, the C++ standard requires argv to be terminated with a null pointer, so you really should define your dummy argv as:
char*argv[] = { "test1", "test2", 0 };
That's because code that parses argv is free to ignore the value of argc and to just loop over the argument vector looking for the terminating null pointer.
Cheers,
Michi.0
