blob: be45b75a52950fec9b93e13eb71391ee439e9b26 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
#include <u.h>
#include <sys/stat.h>
#include <libc.h>
#include <draw.h>
vlong
_drawflength(int fd)
{
struct stat s;
if(fstat(fd, &s) < 0)
return -1;
return s.st_size;
}
|