Re: Debugging "A machine-level exception"
- Posted by gbonvehi Aug 21, 2008
- 1093 views
Sorry about the badly formatted message.
Regarding the second error again, here's some code that will help you debug that one.
According to the documentation, OleCreateFontIndirect returns E_INVALIDARG, E_OUTOFMEMORY, E_UNEXPECTED, E_NOINTERFACE and E_POINTER errors.
Eucom has routines to check for errors, they're just not used there, until now :)
On eucom.ew, quick_activate function add below the line:
ok = c_func( OleCreateFontIndirect, { pfont, riid, ppvIFont } )
This code:
if is_error(ok) then com_err_out(1) -- Print the error on console com_error(ok) -- Display the error on console while get_key() = -1 do -- Wait for key press end while ?1/0 -- Crash end if