Reading errno from msvcrt.dll

new topic     » topic index » view thread      » older message » newer message

How do I get the value of errno and _doserrno from msvcrt.dll? I'm using
define_c_var()(using "_errno" and "__doserrno") to get the addresses. I then use
peek4s() to see what their values are. No matter what, I am getting 28075240 and
28071656 decimal respectively. These are invalid error numbers (I've verified
that by using strerror).

I know I am getting the error that I am intentionally causing because I can use
perror to print the error message.

I might not need this, but I would like to rely on more information than just -1
returned from an IO function.

Anyone have experience in this?

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu