Example #1
0
 public ExceptionUnwindStopReason(CorAppDomain appDomain, CorThread thread,
                                  CorDebugExceptionUnwindCallbackType eventType, int flags)
 {
     m_appDomain = appDomain;
     m_thread    = thread;
     m_eventtype = eventType;
     m_flags     = flags;
 }
Example #2
0
 public ExceptionUnwind2EventArgs(AppDomain appDomain, Thread thread,
                                  CorDebugExceptionUnwindCallbackType eventType,
                                  int flags)
     : base(appDomain, thread)
 {
     m_eventType = eventType;
     m_flags     = flags;
 }
Example #3
0
 public ExceptionUnwindDebugCallbackEventArgs(ICorDebugAppDomain?pAppDomain, ICorDebugThread?pThread, CorDebugExceptionUnwindCallbackType dwEventType, CorDebugExceptionFlags dwFlags)
     : base(pAppDomain)
 {
     AppDomain = pAppDomain;
     Thread    = pThread;
     EventType = dwEventType;
     Flags     = dwFlags;
 }
 protected override unsafe int OnExceptionUnwind(
     CorDebugAppDomain pAppDomain,
     CorDebugThread pThread,
     CorDebugExceptionUnwindCallbackType dwEventType,
     uint dwFlags)
 {
     ExceptionUnwind?.Invoke(this, pAppDomain, pThread, dwEventType, dwFlags);
     return(Continue());
 }
Example #5
0
 public void ExceptionUnwind(IntPtr pAppDomain, IntPtr pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
 {
     Call(delegate
     {
         _managedCallback.ExceptionUnwind(
             _connector.MarshalAs <ICorDebugAppDomain>(pAppDomain),
             _connector.MarshalAs <ICorDebugThread>(pThread),
             dwEventType,
             dwFlags);
     });
 }
Example #6
0
 public void ExceptionUnwind(IntPtr pAppDomain, IntPtr pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
 {
     Call(delegate {
         callbackSwitch.ExceptionUnwind(
             MTA2STA.MarshalIntPtrTo <ICorDebugAppDomain>(pAppDomain),
             MTA2STA.MarshalIntPtrTo <ICorDebugThread>(pThread),
             dwEventType,
             dwFlags
             );
     });
 }
 void ICorDebugManagedCallback2.ExceptionUnwind(
     ICorDebugAppDomain appDomain,
     ICorDebugThread thread,
     CorDebugExceptionUnwindCallbackType eventType,
     uint flags)
 {
     if (DebugOutput)
     {
         Console.WriteLine("info: ExceptionUnwind2");
     }
     appDomain.Continue(0);
 }
		public void ExceptionUnwind(ICorDebugAppDomain pAppDomain, ICorDebugThread pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
		{
			ManagedCallback managedCallback = GetProcessCallbackInterface("ExceptionUnwind", pAppDomain);
			if (managedCallback != null) {
				managedCallback.ExceptionUnwind(pAppDomain, pThread, dwEventType, dwFlags);
			}
		}
 public void ExceptionUnwind(ICorDebugAppDomain pAppDomain, ICorDebugThread pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
 {
     HandleEvent(pAppDomain);
 }
Example #10
0
            void ICorDebugManagedCallback2.ExceptionUnwind(ICorDebugAppDomain pAppDomain, ICorDebugThread pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
            {
                var ev = new CorEventArgs(new CorAppDomain(pAppDomain, p_options));

                GetOwner(ev.Controller).DispatchEvent(ev);

                FinishEvent(ev);
            }
Example #11
0
 protected abstract int OnExceptionUnwind(
     CorDebugAppDomain pAppDomain,
     CorDebugThread pThread,
     CorDebugExceptionUnwindCallbackType dwEventType,
     uint dwFlags);
Example #12
0
            public void ExceptionUnwind(ICorDebugAppDomain pAppDomain, ICorDebugThread pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
            {
                try
                {
                    _EnterCallback();

                    _CallbackNotImplemented();

                    _CallbackEvent("ExceptionUnwind");
                }
                catch (Exception e)
                {
                    _CallbackException(e);
                }
            }
Example #13
0
 public void ExceptionUnwind([In, MarshalAs(UnmanagedType.Interface)] ICorDebugAppDomain pAppDomain, [In, MarshalAs(UnmanagedType.Interface)] ICorDebugThread pThread, [In] CorDebugExceptionUnwindCallbackType dwEventType, [In] uint dwFlags)
 {
     throw new NotImplementedException();
 }
 public void ExceptionUnwind(IntPtr pAppDomain, IntPtr pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
 {
     Call(delegate
     {
         _managedCallback.ExceptionUnwind(
             _connector.MarshalAs<ICorDebugAppDomain>(pAppDomain),
             _connector.MarshalAs<ICorDebugThread>(pThread),
             dwEventType,
             dwFlags);
     });
 }
Example #15
0
 public void ExceptionUnwind(System.IntPtr pAppDomain, System.IntPtr pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
 {
     this.WrappedObject.ExceptionUnwind(pAppDomain, pThread, dwEventType, dwFlags);
 }
 public void ExceptionUnwind(ICorDebugAppDomain pAppDomain, ICorDebugThread pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
 {
     HandleEvent(pAppDomain);
 }
Example #17
0
//		public void Exception2(ICorDebugAppDomain pAppDomain, ICorDebugThread pThread, ICorDebugFrame pFrame, uint nOffset, CorDebugExceptionCallbackType exceptionType, uint dwFlags)
//		{
//			EnterCallback(PausedReason.Exception, "Exception2 (type=" + exceptionType.ToString() + ")", pThread);
//			
//			// This callback is also called from Exception(...)!!!! (the .NET 1.1 version)
//			// Watch out for the zeros and null!
//			// Exception -> Exception2(pAppDomain, pThread, null, 0, exceptionType, 0);
//			
//			process.SelectedThread.CurrentException = new Exception(new Value(process, new Expressions.CurrentExceptionExpression(), process.SelectedThread.CorThread.CurrentException));
//			process.SelectedThread.CurrentException_DebuggeeState = process.DebuggeeState;
//			process.SelectedThread.CurrentExceptionType = (ExceptionType)exceptionType;
//			process.SelectedThread.CurrentExceptionIsUnhandled = (ExceptionType)exceptionType == ExceptionType.Unhandled;
//			
//			if (process.SelectedThread.CurrentExceptionIsUnhandled ||
//			    process.PauseOnHandledException) 
//			{
//				pauseOnNextExit = true;
//			}
//			ExitCallback();
//		}
		
		public void ExceptionUnwind(ICorDebugAppDomain pAppDomain, ICorDebugThread pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
		{
			EnterCallback(PausedReason.ExceptionIntercepted, "ExceptionUnwind", pThread);
			
			if (dwEventType == CorDebugExceptionUnwindCallbackType.DEBUG_EXCEPTION_INTERCEPTED) {
				ExitCallback_Paused();
			} else {
				ExitCallback_Continue();
			}
		}
Example #18
0
 public virtual void ExceptionUnwind(ICorDebugAppDomain pAppDomain, ICorDebugThread pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
 {
     pAppDomain.Continue(0);
 }
 public ExceptionUnwindDebugCallbackEventArgs(ICorDebugAppDomain pAppDomain, ICorDebugThread pThread, CorDebugExceptionUnwindCallbackType dwEventType, CorDebugExceptionFlags dwFlags)
     : base(pAppDomain)
 {
     this.AppDomain = pAppDomain;
     this.Thread    = pThread;
     this.EventType = dwEventType;
     this.Flags     = dwFlags;
 }
Example #20
0
 public void ExceptionUnwind(ICorDebugAppDomain pAppDomain, ICorDebugThread pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
 {
     throw new NotImplementedException();
 }
		void ICorDebugManagedCallback.ExceptionUnwind (CorDebugAppDomain appDomain, CorDebugThread m_thread, CorDebugExceptionUnwindCallbackType m_type, int i)
		{
		}
Example #22
0
 public void OnExceptionUnwind(AppDomain appDomainRef, Thread threadRef, CorDebugExceptionUnwindCallbackType dwEventType, int dwFlags)
 {
     _handleEvent(ManagedCallbackType.OnExceptionUnwind2, new ExceptionUnwind2EventArgs(appDomainRef, threadRef, dwEventType, dwFlags, ManagedCallbackType.OnExceptionUnwind2));
 }
Example #23
0
		public ExceptionUnwindDebugCallbackEventArgs(ICorDebugAppDomain pAppDomain, ICorDebugThread pThread, CorDebugExceptionUnwindCallbackType dwEventType, CorDebugExceptionFlags dwFlags)
			: base(pAppDomain) {
			this.AppDomain = pAppDomain;
			this.Thread = pThread;
			this.EventType = dwEventType;
			this.Flags = dwFlags;
		}
			public ManagedCallbackExceptionUnwind (CorDebugThread thread, CorDebugFrame frame, CorDebugExceptionUnwindCallbackType type) : base (thread)
			{
				Debug.Assert (type == CorDebugExceptionUnwindCallbackType.DEBUG_EXCEPTION_INTERCEPTED, "UnwindBegin is not supported");
				m_type = type;
				m_frame = frame;
			}
Example #25
0
 public void ExceptionUnwind(ICorDebugAppDomain pAppDomain, ICorDebugThread pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
 {
     pAppDomain.Continue(0);
 }
 public static void ExceptionUnwind(this ICorDebugManagedCallback2 instance, IntPtr pAppDomain, IntPtr pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
 {
     instance.ExceptionUnwind(pAppDomain, pThread, dwEventType, dwFlags);
 }
		public void ExceptionUnwind(IntPtr pAppDomain, IntPtr pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
		{
			Call(delegate {
			     	callbackSwitch.ExceptionUnwind(
			     		MTA2STA.MarshalIntPtrTo<ICorDebugAppDomain>(pAppDomain),
			     		MTA2STA.MarshalIntPtrTo<ICorDebugThread>(pThread),
			     		dwEventType,
			     		dwFlags
			     	);
			     });
		}
		public void ExceptionUnwind(ICorDebugAppDomain pAppDomain, ICorDebugThread pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
		{
			EnterCallback("ExceptionUnwind", pThread);
			
			if (dwEventType == CorDebugExceptionUnwindCallbackType.DEBUG_EXCEPTION_INTERCEPTED) {
				pauseOnNextExit = true;
			}
			ExitCallback();
		}
Example #29
0
 public ExceptionUnwindStopReason(CorAppDomain appDomain, CorThread thread,
                                    CorDebugExceptionUnwindCallbackType eventType, int flags)
 {
     m_appDomain = appDomain;
     m_thread = thread;
     m_eventtype = eventType;
     m_flags = flags;
 }
Example #30
0
 public CorExceptionUnwind2EventArgs(CorAppDomain appDomain, CorThread thread,
                                     CorDebugExceptionUnwindCallbackType eventType,
                                     int flags,
                                     ManagedCallbackType callbackType)
     : base(appDomain, thread, callbackType)
 {
     m_eventType = eventType;
     m_flags = flags;
 }
 public ManagedCallbackExceptionUnwind(CorDebugThread thread, CorDebugFrame frame, CorDebugExceptionUnwindCallbackType type) : base(thread)
 {
     Debug.Assert(type == CorDebugExceptionUnwindCallbackType.DEBUG_EXCEPTION_INTERCEPTED, "UnwindBegin is not supported");
     m_type  = type;
     m_frame = frame;
 }
 public void ExceptionUnwind(ICorDebugAppDomain pAppDomain, ICorDebugThread pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
 {
     Console.WriteLine("ExceptionUnwind");
     pAppDomain.Continue(0);
 }
        public void ExceptionUnwind(ICorDebugAppDomain pAppDomain, ICorDebugThread pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
        {
            ManagedCallback managedCallback = GetProcessCallbackInterface(pAppDomain);

            if (managedCallback != null)
            {
                managedCallback.ExceptionUnwind(pAppDomain, pThread, dwEventType, dwFlags);
            }
        }
Example #34
0
            private static void OnExceptionUnwind(IntPtr thisPtr, IntPtr appDomainRef, IntPtr threadRef, CorDebugExceptionUnwindCallbackType dwEventType, int dwFlags)
            {
                var shadow   = ToShadow <ManagedCallback2Shadow>(thisPtr);
                var callback = (ManagedCallbackImpl)shadow.Callback;

                callback.OnExceptionUnwind(new AppDomain(appDomainRef), new Thread(threadRef), dwEventType, dwFlags);
            }
 void ICorDebugManagedCallback2.ExceptionUnwind(IntPtr pAppDomain, IntPtr pThread, CorDebugExceptionUnwindCallbackType dwEventType, CorDebugExceptionFlags dwFlags)
 {
     dbg.OnManagedCallbackFromAnyThread(() => new ExceptionUnwindDebugCallbackEventArgs(I <ICorDebugAppDomain>(pAppDomain), I <ICorDebugThread>(pThread), dwEventType, dwFlags));
 }
Example #36
0
 void ICorDebugManagedCallback.ExceptionUnwind(CorDebugAppDomain appDomain, CorDebugThread m_thread, CorDebugExceptionUnwindCallbackType m_type, int i)
 {
 }
Example #37
0
 void ICorDebugManagedCallback2.ExceptionUnwind(ICorDebugAppDomain ad, ICorDebugThread thread,
                                                CorDebugExceptionUnwindCallbackType eventType, uint flags)
 {
     HandleEvent(ManagedCallbackType.OnExceptionUnwind2,
                               new CorExceptionUnwind2EventArgs(ad == null ? null : new CorAppDomain(ad),
                                                 thread == null ? null : new CorThread(thread),
                                                 eventType,
                                                 (int)flags,
                                                 ManagedCallbackType.OnExceptionUnwind2));
 }
Example #38
0
        public void ExceptionUnwind(ICorDebugAppDomain pAppDomain, ICorDebugThread pThread, CorDebugExceptionUnwindCallbackType dwEventType, uint dwFlags)
        {
            EnterCallback(PausedReason.ExceptionIntercepted, "ExceptionUnwind", pThread);

            if (dwEventType == CorDebugExceptionUnwindCallbackType.DEBUG_EXCEPTION_INTERCEPTED)
            {
                pauseOnNextExit = true;
            }
            ExitCallback();
        }