{"action":"created","issue":{"url":"https://api.github.com/repos/gitextensions/gitextensions/issues/1962","labels_url":"https://api.github.com/repos/gitextensions/gitextensions/issues/1962/labels{/name}","comments_url":"https://api.github.com/repos/gitextensions/gitextensions/issues/1962/comments","events_url":"https://api.github.com/repos/gitextensions/gitextensions/issues/1962/events","html_url":"https://github.com/gitextensions/gitextensions/issues/1962","id":16748892,"number":1962,"title":"Apply patch is crashing","user":{"login":"regnarock","id":4267223,"avatar_url":"https://avatars.githubusercontent.com/u/4267223?v=3","gravatar_id":"","url":"https://api.github.com/users/regnarock","html_url":"https://github.com/regnarock","followers_url":"https://api.github.com/users/regnarock/followers","following_url":"https://api.github.com/users/regnarock/following{/other_user}","gists_url":"https://api.github.com/users/regnarock/gists{/gist_id}","starred_url":"https://api.github.com/users/regnarock/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/regnarock/subscriptions","organizations_url":"https://api.github.com/users/regnarock/orgs","repos_url":"https://api.github.com/users/regnarock/repos","events_url":"https://api.github.com/users/regnarock/events{/privacy}","received_events_url":"https://api.github.com/users/regnarock/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/gitextensions/gitextensions/labels/waffle:needs%20review","name":"waffle:needs review","color":"ededed"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2013-07-15T11:07:46Z","updated_at":"2015-04-19T16:30:36Z","closed_at":null,"body":"I just tried to apply a trivial patch on my local repository through the GitExtensions interface. (version 2.46)\r\n\r\nHere is the patch : https://drupal.org/files/views-fix-destination-link-for-ajax-1036962-29.patch (quite trivial as you can see).\r\n\r\nI selected the patch then the folder to apply it. Clicked on the \"apply\" button and... crash.\r\n\r\nNow I have the \"You are in the middle of a patch apply\" popping in red on the bottom-right corner (as usual in those cases). But when I click on it, GE crash again. The same goes for the Commands->Apply Patch menu."},"comment":{"url":"https://api.github.com/repos/gitextensions/gitextensions/issues/comments/94294444","html_url":"https://github.com/gitextensions/gitextensions/issues/1962#issuecomment-94294444","issue_url":"https://api.github.com/repos/gitextensions/gitextensions/issues/1962","id":94294444,"user":{"login":"astra07","id":12020818,"avatar_url":"https://avatars.githubusercontent.com/u/12020818?v=3","gravatar_id":"","url":"https://api.github.com/users/astra07","html_url":"https://github.com/astra07","followers_url":"https://api.github.com/users/astra07/followers","following_url":"https://api.github.com/users/astra07/following{/other_user}","gists_url":"https://api.github.com/users/astra07/gists{/gist_id}","starred_url":"https://api.github.com/users/astra07/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/astra07/subscriptions","organizations_url":"https://api.github.com/users/astra07/orgs","repos_url":"https://api.github.com/users/astra07/repos","events_url":"https://api.github.com/users/astra07/events{/privacy}","received_events_url":"https://api.github.com/users/astra07/received_events","type":"User","site_admin":false},"created_at":"2015-04-19T16:30:36Z","updated_at":"2015-04-19T16:30:36Z","body":"The same issue in Git Extensions 2.44, it definitely relates to certain patch!\r\nPlease let us know what is the work around of the problem in Git Extensions?\r\nAnd in what version will be fixed?\r\nThanks in advance!\r\n\r\nStack trace \r\nat System.Text.RegularExpressions.Regex.Match(String input)\r\n   at GitCommands.GitModule.AppendQuotedString(String str1, String str2)\r\n   at GitCommands.GitModule.GetRebasePatchFiles()\r\n   at GitUI.PatchGrid.Initialize()\r\n   at GitUI.FormApplyPatch.EnableButtons()\r\n   at GitUI.GitUICommands.<>c__DisplayClass19.<StartApplyPatchDialog>b__18()\r\n   at GitUI.GitUICommands.DoAction(IWin32Window owner, Boolean requiresValidWorkingDir, GitUIEventHandler preEvent, GitUIPostActionEventHandler postEvent, Func`1 action)\r\n   at GitUI.GitUICommands.StartApplyPatchDialog(IWin32Window owner, String patchFile)\r\n   at GitUI.FormBrowse.RebaseClick(Object sender, EventArgs e)\r\n   at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)\r\n   at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)\r\n   at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)\r\n   at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)\r\n   at System.Windows.Forms.Control.WndProc(Message& m)\r\n   at System.Windows.Forms.ToolStrip.WndProc(Message& m)\r\n   at System.Windows.Forms.StatusStrip.WndProc(Message& m)\r\n   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)\r\n![gitextensions_crash](https://cloud.githubusercontent.com/assets/12020818/7220287/40afcfa8-e6ca-11e4-9d70-96d707c809fa.png)\r\n"}}