mirror of
https://github.com/opensim/opensim.git
synced 2026-08-08 02:05:34 +08:00
get PID from Environment.ProcessId
This commit is contained in:
@@ -86,7 +86,7 @@ namespace OpenSim.Framework.Servers
|
||||
|
||||
try
|
||||
{
|
||||
string pidstring = System.Diagnostics.Process.GetCurrentProcess().Id.ToString();
|
||||
string pidstring = Environment.ProcessId.ToString();
|
||||
|
||||
using (FileStream fs = File.Create(path))
|
||||
{
|
||||
|
||||
@@ -226,11 +226,11 @@ namespace OpenSim
|
||||
throw new Exception("CombineContiguousRegions not suported");
|
||||
}
|
||||
|
||||
string pidFile = startupConfig.GetString("PIDFile", String.Empty);
|
||||
if (pidFile != String.Empty)
|
||||
string pidFile = startupConfig.GetString("PIDFile", string.Empty);
|
||||
if (pidFile.Length > 0)
|
||||
CreatePIDFile(pidFile);
|
||||
|
||||
userStatsURI = startupConfig.GetString("Stats_URI", String.Empty);
|
||||
userStatsURI = startupConfig.GetString("Stats_URI", string.Empty);
|
||||
|
||||
m_securePermissionsLoading = startupConfig.GetBoolean("SecurePermissionsLoading", true);
|
||||
|
||||
@@ -355,7 +355,7 @@ namespace OpenSim
|
||||
|
||||
// Sure is not the right place for this but do the job...
|
||||
// Must always be called before (all) / the HTTP servers starting for the Certs creation or renewals.
|
||||
if(startupConfig.GetBoolean("EnableSelfsignedCertSupport", false))
|
||||
if (startupConfig.GetBoolean("EnableSelfsignedCertSupport", false))
|
||||
{
|
||||
if(!File.Exists("SSL\\ssl\\"+ startupConfig.GetString("CertFileName") +".p12") || startupConfig.GetBoolean("CertRenewOnStartup"))
|
||||
{
|
||||
|
||||
@@ -180,9 +180,10 @@ namespace OpenSim.Server.Base
|
||||
RegisterCommonAppenders(startupConfig);
|
||||
LogEnvironmentInformation();
|
||||
|
||||
if (startupConfig.GetString("PIDFile", String.Empty) != String.Empty)
|
||||
string pidfile = startupConfig.GetString("PIDFile", string.Empty);
|
||||
if (pidfile.Length > 0)
|
||||
{
|
||||
CreatePIDFile(startupConfig.GetString("PIDFile"));
|
||||
CreatePIDFile(pidfile);
|
||||
}
|
||||
|
||||
RegisterCommonCommands();
|
||||
|
||||
Reference in New Issue
Block a user