Browse Source

Merge pull request #4848 from 1208nn/patch-2

Update schdtask related code
pull/5655/head
2dust 8 months ago committed by GitHub
parent
commit
3b4cc2c5f2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 4
      v2rayN/v2rayN/Common/Utile.cs

4
v2rayN/v2rayN/Common/Utile.cs

@ -1136,7 +1136,7 @@ namespace v2rayN
task.Settings.ExecutionTimeLimit = TimeSpan.Zero;
task.Triggers.Add(new LogonTrigger { UserId = logonUser, Delay = TimeSpan.FromSeconds(10) });
task.Principal.RunLevel = TaskRunLevel.Highest;
task.Actions.Add(new ExecAction(deamonFileName));
task.Actions.Add(new ExecAction(deamonFileName, null, Path.GetDirectoryName(deamonFileName)));
taskService.RootFolder.RegisterTaskDefinition(TaskName, task);
}
@ -1186,4 +1186,4 @@ namespace v2rayN
#endregion Windows API
}
}
}

Loading…
Cancel
Save