URI:
       tunix.c - plan9port - [fork] Plan 9 from user space
  HTML git clone git://src.adamsgaard.dk/plan9port
   DIR Log
   DIR Files
   DIR Refs
   DIR README
   DIR LICENSE
       ---
       tunix.c (177B)
       ---
            1 #include <u.h>
            2 #include <sys/stat.h>
            3 #include <libc.h>
            4 #include <draw.h>
            5 
            6 vlong
            7 _drawflength(int fd)
            8 {
            9         struct stat s;
           10 
           11         if(fstat(fd, &s) < 0)
           12                 return -1;
           13         return s.st_size;
           14 }