tempPath = PL_strdup(prefValue);
tempFilePath = PL_strdup(prefValue);
char * WH_TempName(const char * prefix){	nsresult res;	nsString tempPath = "c:\\temp\\";	#define PREF_LENGTH 128 	char prefValue[PREF_LENGTH];	PRInt32 prefLength = PREF_LENGTH;	NS_WITH_SERVICE(nsIPref, prefs, kPrefCID, &res);     if (prefs && NS_SUCCEEDED(res))	{		res = prefs->GetCharPref("browser.download_directory", prefValue, &prefLength);		if (NS_SUCCEEDED(res) && prefLength > 0)			tempPath = PL_strdup(prefValue);	}		if (tempPath.Last() != '\\')		tempPath += '\\';	tempPath += prefix;	tempPath += "01.txt";	//JFD, need to be smarter than that!	return tempPath.ToNewCString();}