Björkus "No time_t to Die" Dorkus @thephd.dev · Mar 19

Forgot how much I hate POSIX and most other C APIs, in general. "Hey, if this thread is not joinable, it's EINVAL." Cool, thanks, I apprecia- "It's also EINVAL if another thread is waiting to join this one." .....

58 likes 3 replies

?

Replies

Gian-Carlo Pascutto · Mar 20

You can even have the same error for two problems that are so far apart I can't...just...

Björn Fahller 🇺🇦🇬🇱🇪🇺🇸🇪 · Mar 19

What are the chances that the programmer who caused EINVAL can programmatically save the situation?

Björkus "No time_t to Die" Dorkus · Mar 19

LAW OF USEFUL RETURNS also includes CONSEQUENCE OF USEFUL ERROR CODES: don't overlap distinct, important states into one return code!