コード例 #1
0
        private void SendErrorPage(Exception applicationEx)
        {
            var errorPage = new Fos.CustomPages.ApplicationErrorPage(applicationEx);

            OwinContext.SetResponseHeader("Content-Type", "text/html");
            OwinContext.ResponseStatusCodeAndReason = "500 Internal Server Error";

            using (var sw = new StreamWriter(Stdout))
            {
                sw.Write(errorPage.Contents);
            }

            Stdout.Flush();
        }
コード例 #2
0
ファイル: FosRequest.cs プロジェクト: james-andrewsmith/Fos
		private void SendErrorPage(Exception applicationEx)
		{
			var errorPage = new Fos.CustomPages.ApplicationErrorPage(applicationEx);

			OwinContext.SetResponseHeader("Content-Type", "text/html");
			OwinContext.ResponseStatusCodeAndReason = "500 Internal Server Error";

			using (var sw = new StreamWriter(Stdout))
			{
				sw.Write(errorPage.Contents);
			}

            Stdout.Flush();
		}