From 51805bedcbaf29d767c50cc8de146784164b5e04 Mon Sep 17 00:00:00 2001 From: hiiru Date: Fri, 10 Apr 2015 19:19:18 +0200 Subject: [PATCH] fixed bugs!!!1111 those fixed are so damn. important and useful ^^ :shipit: --- BugFixingSim/src/BugFixingSim/Program.cs | 25 +++++++++++++++++++----- 1 file changed, 20 insertions(+), 5 deletions(-) diff --git a/BugFixingSim/src/BugFixingSim/Program.cs b/BugFixingSim/src/BugFixingSim/Program.cs index 4f5447f2300c..29d71fd556dc 100644 --- a/BugFixingSim/src/BugFixingSim/Program.cs +++ b/BugFixingSim/src/BugFixingSim/Program.cs @@ -1,4 +1,4 @@ -using System; +using System; using System.Collections.Generic; namespace BugFixingSim @@ -10,7 +10,7 @@ public void Main(string[] args) Console.WriteLine("Bugfixing sim 0.0.1-alpha, fix bugs yourself!"); Console.WriteLine(); int task = 1; - int bugfixes=0; + int bugfixes = 0; var memleak = new List(); while (true) { @@ -42,8 +42,20 @@ public void Main(string[] args) private void StackOverflow() { - //because i'm too lazy to throw the StackOverflowException myself - StackOverflow(); + try + { + //because i'm too lazy to throw the StackOverflowException myself + StackOverflow(); + } +#if ASPNET50 + catch (StackOverflowException soe) +#else + catch (Exception e) +#endif + { + // what better way is there to handle this great exception than to catch it? :P + // at least I also added the coreCLR fallback. + } } private bool CheckBugfix(string line) @@ -58,10 +70,13 @@ private bool CheckBugfix(string line) case "fixed": case "done": case "workaround": - case "intented": + case "intended": case "fix": case "solved": return true; + //legacy support for old version and ppl like me who can't type correctly!!!11111 + case "intented": + return true; } } return false;