Logo Search packages:      
Sourcecode: fastdep version File versions  Download package

bool MappedFile::open ( const std::string &  name  ) 

Opens a file for memory mapping

Definition at line 104 of file MappedFile.cc.

{
      fd = ::open(name.c_str(), O_RDONLY);
      opened_ = fd >= 0 ? true : false ;
      if(opened_)
      {
            struct stat st;
            fstat(fd, &st);
            file_size = st.st_size;
            last_change = st.st_mtime;
            mapsize = st.st_size;
      }
      return opened_;
}


Generated by  Doxygen 1.6.0   Back to index