perror.c
来自「基于4个mips核的noc设计」· C语言 代码 · 共 26 行
C
26 行
/* * lib-src/ansi/stdio/perror.c * ANSI/ISO 9899-1990, Section 7.9.10.4. * * void perror(const char *s) * Print an error message to the standard error stream. */#include <stdio.h>#include <errno.h>#include "shared_libc.h"voidperror(const char *s){ if (s != NULL && *s != 0) { fputs(s, stderr); fputs(": ", stderr); } if ((unsigned)errno < _sys_nerr) fputs((char *)_sys_errlist[errno], stderr); else fprintf(stderr, (char *)_sys_errformat, errno); fputc('\n', stderr);}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?