I'm working on Webclient 2.0, developing on RedHat GNU/Linux 7.2, and
I'm using the ever so excellent TestGtkEmbed as my guide to the right
way to use the embedding APIs.
During the startup sequence, TestGtkEmbed causes the nsIAppShell to be
started up. I took the code that does that and moved it over to
webclient, lik this:
// appshell
// XXX startup appshell service?
// XXX create offscreen window for appshell service?
// XXX remove X prop from offscreen window?
nsCOMPtr<nsIAppShell> appShell;
appShell = do_CreateInstance(kAppShellCID);
if (!appShell) {
::util_ThrowExceptionToJava(env,
"Failed to create AppShell");
return;
}
rv = appShell->Create(0, nsnull);
PR_LOG(prLogModuleInfo, PR_LOG_DEBUG,
("WrapperFactoryImpl_nativeAppSetup: AppShell create rv: %d\n",
rv));
if (NS_FAILED(rv)) {
::util_ThrowExceptionToJava(env,
"Failed to create AppShell");
return;
}
rv = appShell->Spinup();
PR_LOG(prLogModuleInfo, PR_LOG_DEBUG,
("WrapperFactoryImpl_nativeAppSetup: AppShell spinup rv: %d\n",
rv));
if (NS_FAILED(rv)) {
::util_ThrowExceptionToJava(env,
"Failed to Spinup AppShell");
return;
}
I'm getting
Program received signal SIGSEGV, Segmentation fault.
0x4b05c35c in ?? () from /usr/lib/libgdk-1.2.so.0
When I do
rv = appShell->Create(0, nsnull);
Can someone please help me with this?
Thanks,
Ed