__syscall_error.c 271 B

12345678910111213141516
  1. /*
  2. * Copyright (C) 2017 Hangzhou C-SKY Microsystems co.,ltd.
  3. *
  4. * Licensed under the LGPL v2.1 or later, see the file COPYING.LIB
  5. * in this tarball.
  6. */
  7. #include <errno.h>
  8. #include <features.h>
  9. int __syscall_error(int err_no)
  10. {
  11. __set_errno(-err_no);
  12. return -1;
  13. }