some coverity fixes.
[minix.git] / lib / libc / sys-minix / read.c
blobb14391203bed3f633c0464f65bf6ddb6dfc9e41f
1 #include <sys/cdefs.h>
2 #include <lib.h>
3 #include "namespace.h"
5 #include <unistd.h>
7 #ifdef __weak_alias
8 __weak_alias(read, _read)
9 #endif
11 ssize_t read(int fd, void *buffer, size_t nbytes)
13 message m;
15 m.m1_i1 = fd;
16 m.m1_i2 = nbytes;
17 m.m1_p1 = (char *) buffer;
18 return(_syscall(VFS_PROC_NR, READ, &m));