有一个进程A,当A出错时,弹出系统错误对话框(例如内存报错的"指定内存不能为读")。
现在我想在另外一个进程B中知道A弹出系统错误的,这样我能够实现重启A,请问怎么实现?
求教高手。
现在我想在另外一个进程B中知道A弹出系统错误的,这样我能够实现重启A,请问怎么实现?
求教高手。
解决方案 »
- listCtrl控件虚表怎么实现的?
- 关于MFC的(AFX_PMSG)(AFX_PMSGW)转换的请教
- Gethostname,gethostbyaddr,getcomputername,getusername什么关系。
- MFC中, 创建的DC在什么时候才需要Release ?
- 映射模式的问题,求助。
- 散分,和大家讨论读了《统一软件开发过程》和《Windows核心编程》
- 请问: 如何在vc中编程创建access数据库(包括表的创建)?
- 怎样清空cricheditview中的字符串?
- 我的应用程序已经成功的打开了一个数据文件,请问怎样判断有没有别的程序正试图打开该数据文件?
- 大人进,急,在线等!关于creatfile,readfile,writefile函数
- 请问CComSafeArray类 在ATL哪个头文件中声明。
- 奇怪的问题,使用了双缓冲和设置WS_CLIPCHILDREN属性,当改变主窗口大小时,主界面上的其他控件还是会闪!
MSDN
CreateProcess dwCreationFlags ,
Process Creation Flags
DEBUG_PROCESS:
The calling thread starts and debugs the new process and all any child processes of the new process that are created with DEBUG_PROCESS. It can receive all related debug events using the WaitForDebugEvent function.
If this flag is combined with DEBUG_ONLY_THIS_PROCESS, the caller debugs only the new process.Windows Me/98/95: This flag is not valid if the new process is a 16-bit application.
如果不是,可以考虑用钩子,写个 dll 注入到远程进程,注入时给那个程序添加一个自定义的 SEH 处理函数。