setmode again

Steven Schveighoffer schveiguy at yahoo.com
Fri Aug 8 13:10:40 PDT 2008


"Brian Myers" wrote
> No, I haven't because I thought that would result in a compiler or linker 
> error. What happens is the function is executed at run time, but has no 
> effect. I think I have a better idea now thought:

Try the extern(Windows).  The difference is the call stack layout.  what 
could be happening is you are calling a function one way, but the function 
expects to be called a different way.  So it isn't reading the parameters 
like you think it is (in fact, it might be reading garbage).

You won't get a compiler or linker error because you are not linking the 
function in, you are dynamically loading it.

-Steve 





More information about the Digitalmars-d mailing list