madExceptPatch on IDE compile is not always performed

delphi package - automated exception handling

madExceptPatch on IDE compile is not always performed

Postby x3mike » Fri Apr 26, 2013 1:04 pm

Hello,

I have a strange problem, when I compile some larger project of mine, the exe is not patched after the compilation within the IDE all the time. This results in not bugreport handled exceptions.
When I manually use "madExceptPatch" afterwards the exe gets patched and madExcept works as expected. The compiled exe has 67MB in size.

For some testing I created a new project containing a single empty form and here all works fine.

How can I ensure the application gets patched?

Regards,
Michael
x3mike
 
Posts: 8
Joined: Fri Apr 26, 2013 12:50 pm

Re: madExceptPatch on IDE compile is not always performed

Postby madshi » Fri Apr 26, 2013 1:27 pm

I've had two other customers report the same problem recently. It seems that when your exe is very big and the IDE has a very strongly fragmented memory range, mapping the full exe into the IDE process fails, resulting in a failure to perform the patching. A workaround would be to run madExceptPatch as a post-build event. But of course that's not very nice. I'll see if I can do something about this for the next build.
madshi
Site Admin
 
Posts: 10225
Joined: Sun Mar 21, 2004 5:25 pm

Re: madExceptPatch on IDE compile is not always performed

Postby madshi » Mon May 13, 2013 8:13 pm

I've now implemented a workaround: If patching fails inside of the IDE process, madExcept instead automatically starts the "madExceptPatch.exe" helper tool to do the patching. You shouldn't even notice the difference, except that the problem should hopefully be gone now:

http://madshi.net/madCollection.exe (madExcept 4.0.7, installer 2.7.6.0)
madshi
Site Admin
 
Posts: 10225
Joined: Sun Mar 21, 2004 5:25 pm

Re: madExceptPatch on IDE compile is not always performed

Postby Jürgen Bauer » Wed Jun 26, 2013 10:06 am

Hello,
I have a similar Problem with my application which has a exe size of about 100 mb.
Even if I call the external tool madExceptPatch.exe, my application is not patched.
All exceptions are reported "normally" not via madExcept.

Any idea?

Thanks!

Bye,
Jürgen
Jürgen Bauer
 
Posts: 3
Joined: Wed Jun 26, 2013 9:58 am

Re: madExceptPatch on IDE compile is not always performed

Postby madshi » Wed Jun 26, 2013 11:41 am

What does madExceptPatch report? Any warnings/errors?
madshi
Site Admin
 
Posts: 10225
Joined: Sun Mar 21, 2004 5:25 pm

Re: madExceptPatch on IDE compile is not always performed

Postby Jürgen Bauer » Wed Jun 26, 2013 2:37 pm

There are no warnings/Errors reported.
But the application does not show the madExcept screen when exceptions are raised.
Jürgen Bauer
 
Posts: 3
Joined: Wed Jun 26, 2013 9:58 am

Re: madExceptPatch on IDE compile is not always performed

Postby madshi » Wed Jun 26, 2013 2:40 pm

Hmmmm... Are we talking about Delphi or BCB? Can you send me your EXE file and the matching MAP file (if it's Delphi, for BCB please send me the TDS file). I don't need to be able to execute your EXE, just need to be able to run madExceptPatch myself on your EXE.
madshi
Site Admin
 
Posts: 10225
Joined: Sun Mar 21, 2004 5:25 pm

Re: madExceptPatch on IDE compile is not always performed

Postby Jürgen Bauer » Thu Jun 27, 2013 7:25 am

I am using Delphi XE4.
How can I send you my application?
Jürgen Bauer
 
Posts: 3
Joined: Wed Jun 26, 2013 9:58 am

Re: madExceptPatch on IDE compile is not always performed

Postby madshi » Thu Jun 27, 2013 7:54 am

Maybe you can upload it somewhere (e.g. Mediafire) and then send me a link via email?

When creating the EXE you want to send to me, please disable madExcept first, to make sure that your EXE is not yet touched by madExcept at all. Then please zip up the EXE, the map file and the "mes" file.
madshi
Site Admin
 
Posts: 10225
Joined: Sun Mar 21, 2004 5:25 pm

Re: madExceptPatch on IDE compile is not always performed

Postby bwdirks » Wed Feb 04, 2015 7:29 pm

I'm using madExcept 4.0.11 and I'm still getting this error after doing a full build of my application in XE7:
[madExcept Warning] Starting external madExceptPatch tool failed.

I downloaded your DLL injector tool and followed your instructions and this is what I got when I compiled again:
"C:\Users\Public\Documents\Embarcadero\Studio\15.0\tools\madExceptPatch.exe" "C:\DOCSTORE\CarePlans\DSSCarePlans.exe" "C:\Source Code\CarePlans\v0.0.0.1\DSSCarePlans.mes" /dontCheckRtl

All of those paths are correct so why am I still getting this error?
bwdirks
 
Posts: 19
Joined: Wed Feb 04, 2015 7:07 pm

Re: madExceptPatch on IDE compile is not always performed

Postby madshi » Wed Feb 25, 2015 12:26 pm

FJWIW: The problem reported by bwdirks was solved via email: The "Tools" subdirectory was missing. Suspected cause: Too long library path? Manually creating the folder with the madExceptPatch tool inside solved the issue.
madshi
Site Admin
 
Posts: 10225
Joined: Sun Mar 21, 2004 5:25 pm


Return to madExcept

Who is online

Users browsing this forum: No registered users and 15 guests