file_size.cpp 348 B

123456789101112131415161718
  1. //
  2. // $Id$
  3. //
  4. #include<__vic/fs.h>
  5. #include<__vic/posix/file_stat.h>
  6. namespace __vic {
  7. //----------------------------------------------------------------------------
  8. uintmax_t file_size(const char *path)
  9. {
  10. return posix::file_stat(path).size();
  11. }
  12. //----------------------------------------------------------------------------
  13. } // namespace