Bug 460979 - nsIdleServiceGTK.cpp crashes if no X display. r/sr=roc

This commit is contained in:
Joshua Cranmer 2008-10-21 23:35:30 -04:00
parent b0356cef11
commit 7a1c750320

View File

@ -68,14 +68,15 @@ NS_IMPL_ISUPPORTS1(nsIdleServiceGTK, nsIIdleService)
nsIdleServiceGTK::nsIdleServiceGTK()
: mXssInfo(nsnull)
{
#ifdef PR_LOGGING
if (!sIdleLog)
sIdleLog = PR_NewLogModule("nsIIdleService");
#endif
}
static void Initialize()
{
sInitialized = PR_TRUE;
#ifdef PR_LOGGING
sIdleLog = PR_NewLogModule("nsIIdleService");
#endif
// This will leak - See comments in ~nsIdleServiceGTK().
PRLibrary* xsslib = PR_LoadLibrary("libXss.so.1");