repo.or.cz
/
minix3.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
. pci driver now returns devices, even when they have been pci_reserve()d
[minix3.git]
/
lib
/
posix
/
_lstat.c
blob
64e24f057733ca13b1a5288f3ec12836ca4251b6
1
#include <lib.h>
2
#define lstat _lstat
3
#define stat _stat
4
#include <sys/stat.h>
5
#include <string.h>
6
7
PUBLIC
int
lstat
(
name
,
buffer
)
8
_CONST
char
*
name
;
9
struct
stat
*
buffer
;
10
{
11
message m
;
12
int
r
;
13
14
m
.
m1_i1
=
strlen
(
name
) +
1
;
15
m
.
m1_p1
= (
char
*)
name
;
16
m
.
m1_p2
= (
char
*)
buffer
;
17
if
((
r
=
_syscall
(
FS
,
LSTAT
, &
m
)) >=
0
||
errno
!=
ENOSYS
)
18
return
r
;
19
return
_stat
(
name
,
buffer
);
20
}