using System;
using System.CodeDom.Compiler;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Windows;

namespace N2_Patcher
{
	public partial class App : Application
	{
		public App()
		{
		}

		protected override void OnStartup(StartupEventArgs e)
		{
			if (Process.GetProcessesByName(Path.GetFileNameWithoutExtension(Assembly.GetEntryAssembly().Location)).Count<Process>() > 1)
			{
				Environment.Exit(0);
			}
		}
	}
}