Thanks a lot for the response Benjamin! I'm using 1.8 branch. I've solved the problem. I was using gtkembed example to embed mozilla, but I didn't initialize the directory service provide properly.
"Benjamin Smedberg" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Michael R wrote: >> It seems that the problem is the following: >> >> During the initialization the nsNSSComponent call InitializeNSS() >> function. >> Inside InitializeNSS() there is a call to : >> >> rv = >> NS_GetSpecialDirectory(NS_APP_USER_PROFILE_50_DIR,getter_AddRefs(profilePath)); >> >> The value of NS_APP_USER_PROFILE_50_DIR is "ProfD". >> The problem is that this call returns an error. >> It seems that the profile directory is not defined. >> How can I define it ? > > 1) What branch are you using? > 2) A profile is just a directory, but it can only be accessed by a single > process at a time, so Mozilla uses a locking mechanism. This mechanism is > exposed on the trunk in the toolkit: > > http://mxr.mozilla.org/mozilla/source/toolkit/xre/nsXULAppAPI.h#266 > > You have to provide a directoryserviceprovider when you initialize XPCOM > (either with NS_InitXPCOM2 or XRE_InitEmbedding) that responds to ProfD. > The > comments in that file have additional information. If you're using the > branch, you'll probably need to emulate these APIs. There's an old lib > (libprofdirserviceprovider_s) that provides a static lib which provides > some > of these functions. You'd have to take a look in > http://lxr.mozilla.org/mozilla1.8/source/profile/dirserviceprovider/public/nsProfileDirServiceProvider.h > to see how to use it. > > --BDS _______________________________________________ dev-tech-xpcom mailing list [email protected] https://lists.mozilla.org/listinfo/dev-tech-xpcom
