LCC--如何阻止调试器在应用程序启动时中断?
我不确定有多少用户使用 LCC C 编译器和 Windows 的 WEdit GUI,但它有一个可能非常烦人的“功能”。当您使用调试器启动应用程序时,它会在 Main 函数的开头中断该应用程序。如何切断它,以便调试器立即执行代码,直到我停止它或它到达我创建的断点?
I'm not sure of how many users there are out there that use the LCC C compiler and the WEdit GUI for Windows but it has a "feature" that is can get to be quite annoying. When you start an application with the debugger, it breaks the application at the start of the Main function. How can I cut this off so that the debugger immediately executes the code until I halt it or it hits a break point that I've created?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
哇,人们还在使用 LCC...我上次使用它是大约 10 年前。
我反编译了
wedit.exe
并且可以确认没有官方方法可以禁用此行为。如果对你有用的话,我修补了二进制文件。我将其上传到此处。
对于那些担心病毒等问题的人,我修补了取自 这里。 About box 说它是 2009 年 9 月 16 日编译的 4.0 版本。
以下是修补后的函数,供感兴趣的人使用:
LABEL_50
下的if
是我修补的(从 0x75 到 0xEB)。很容易找到这个地方,因为我期望 WriteProcessMemory 用于在正在调试的应用程序的入口点写入 0xCC。
Wow, people still use LCC... Last time I used it was ~10 years ago.
I decompiled
wedit.exe
and can confirm there is no official way to disable this behavior.I patched the binary if that works for you. I uploaded it here.
To those who concerned about viruses and such I patched
wedit
taken from here. About box says it's version 4.0 compiled at Sep 16 2009.Here is patched function to those who interested:
if
underLABEL_50
is what I patched (from 0x75 to 0xEB).It was easy to spot the place because I expected WriteProcessMemory to be used to write 0xCC at entry-point of application that is being debugged.