gforth
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[gforth] errno weirdness


From: Reepca Russelstein
Subject: [gforth] errno weirdness
Date: Wed, 25 Oct 2017 23:44:28 -0500

errno stubbornly refuses to change from 0 no matter what kind of
ridiculous shenanigans I get up to, (-12938 -12932 kill, for example).
Considering C libraries' annoying tendency to communicate all useful
debugging information through that one point, that's pretty
frustrating. The C functions themselves return -1 as is expected, but
errno refuses to change, even when I erroneously use functions from
libc.fs itself (example: s" /argle" s" /blargle" link).

So now I'm stuck trying to figure out why my ptraces are randomly
failing despite using the exact same arguments without knowing what
the error even is. I'm on the latest git checkout presently.

Any ideas? My first guess would be that something in gforth itself is
overwriting errno routinely...

Oh. Well then, turns out the problem only occurs when interactively
checking errno - when it's in a compiled definition it works fine. I
suppose that makes sense, but it's definitely not what I expected. I
don't suppose something could be done about that, even if it's just
adding a note to the manual?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]