protected virtual void OnUnhandledException(HttpExceptionEventArgs e)
        {
            var ev = UnhandledException;

            if (ev != null)
                ev(this, e);
        }
		private void OnException(object sender, HttpExceptionEventArgs e)
		{
			e.Handled = true;
			var buffer = Encoding.UTF8.GetBytes(e.Exception.ToString());
			e.Response.ContentType = "text/plain";
			e.Response.OutputStream.Write(buffer, 0, buffer.Length);
		}
        internal bool RaiseUnhandledException(HttpContext context, Exception exception)
        {
            if (context == null)
                throw new ArgumentNullException("context");

            var e = new HttpExceptionEventArgs(context, exception);

            OnUnhandledException(e);

            return e.Handled;
        }
Exemple #4
0
        internal bool RaiseUnhandledException(HttpContext context, Exception exception)
        {
            if (context == null)
                throw new ArgumentNullException("context");

            var e = new HttpExceptionEventArgs(context, exception);

            OnUnhandledException(e);

            return e.Handled;
        }
Exemple #5
0
 protected virtual void OnUnhandledException(HttpExceptionEventArgs e)
 {
     UnhandledException?.Invoke(this, e);
 }
Exemple #6
0
        void _server_UnhandledException(object sender, HttpExceptionEventArgs e)
        {
            e.Handled = true;

            Log.Warn("Unhandled Help Server exception", e.Exception);
        }