You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

Program.cs 984 B

12 years ago
12 years ago
12 years ago
12 years ago
12345678910111213141516171819202122232425262728293031323334353637
  1. using System;
  2. using System.Collections.Generic;
  3. using System.IO;
  4. using System.Windows.Forms;
  5. namespace shadowsocks_csharp
  6. {
  7. static class Program
  8. {
  9. /// <summary>
  10. /// 应用程序的主入口点。
  11. /// </summary>
  12. [STAThread]
  13. static void Main()
  14. {
  15. try
  16. {
  17. FileStream fs = new FileStream("shadowsocks.log", FileMode.Append);
  18. TextWriter tmp = Console.Out;
  19. StreamWriter sw = new StreamWriter(fs);
  20. sw.AutoFlush = true;
  21. Console.SetOut(sw);
  22. Console.SetError(sw);
  23. }
  24. catch (IOException e)
  25. {
  26. Console.WriteLine(e.ToString());
  27. }
  28. Application.EnableVisualStyles();
  29. Application.SetCompatibleTextRenderingDefault(false);
  30. Application.Run(new Form1());
  31. }
  32. }
  33. }