repo.or.cz
/
ruby-svn.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
* io.c (rb_open_file): encoding in mode string was ignored if perm is
[ruby-svn.git]
/
missing
/
strerror.c
blob
023935a1ff65ccd52ed37ce650937635a5ad5abe
1
/* public domain rewrite of strerror(3) */
2
3
extern
int
sys_nerr
;
4
extern
char
*
sys_errlist
[];
5
6
static char
msg
[
50
];
7
8
char
*
9
strerror
(
int
error
)
10
{
11
if
(
error
<=
sys_nerr
&&
error
>
0
) {
12
return
sys_errlist
[
error
];
13
}
14
sprintf
(
msg
,
"Unknown error (%d)"
,
error
);
15
return
msg
;
16
}