By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,478 Members | 1,703 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,478 IT Pros & Developers. It's quick & easy.


P: 3
Hi Guys,

Have a question regarding the exception filter.

I have a MiniDump class which looks like this:

class MiniDumpHelper


LONG WINAPI exitWithDump(struct _EXCEPTION_POINTERS* exceptionInfo)

then i have a host.cpp class where i have a main()
I try this:

MiniDump *miniDump = new MiniDump();

Then I get this:

error C3867: 'MiniDump::exitWithDump': function call missing argument list;
use '&MiniDump::exitWithDump' to create a pointer to member

So I do:

MiniDump *miniDump = new MiniDump();
SetUnhandledExceptionFilter(&MiniDump::exitWithDum p);

And I get this:

'SetUnhandledExceptionFilter' : cannot convert parameter 1 from 'LONG (__stdcall :MiniDump::* )

I'm really stuck, would really appreciate help, thanks in advance!!

Nov 7 '08 #1
Share this Question
Share on Google+
3 Replies

Expert Mod 5K+
P: 8,916
SetUnhandledExceptionFilter is a C function, can can not pass a pointer to a class member function as a function pointer in this manor to a C function, or indeed any function that requires a pointer to a function as a parameter.

exitWithDump will have either not be a member of the class or be a static member of the classed referenced through the class name rather than an object.
Nov 7 '08 #2

P: 3
Hi banfa,

Thanks so much for your help.
What would you advise me to do in this case?
Nov 7 '08 #3

Expert Mod 5K+
P: 8,916
Hard to say since I don't really know what you are doing or what the purpose of your helper class is meant to be but I would look at making exitWithDump a static member of your class and see if you can make it work that way.
Nov 7 '08 #4

Post your reply

Sign in to post your reply or Sign up for a free account.