errno.c 292 B

1234567891011121314
  1. #include <features.h>
  2. #undef errno
  3. #if 0
  4. /* Unfortunately, this doesn't work... */
  5. int h_errno __attribute__ ((section (".bss"))) = 0;
  6. int errno __attribute__ ((section (".bss"))) = 0;
  7. #else
  8. int errno = 0;
  9. int h_errno = 0;
  10. #endif
  11. weak_alias (errno, _errno)
  12. weak_alias(h_errno, _h_errno);