| 965 | } |
| 966 | |
| 967 | bool MountSystem::isReadOnly(const Path& path) |
| 968 | { |
| 969 | // first check to see if filesystem is read only |
| 970 | FileSystemRef fs = getFileSystem(path); |
| 971 | if ( fs.isNull() ) |
| 972 | // no filesystem owns this file...oh well, return false |
| 973 | return false; |
| 974 | if (fs->isReadOnly()) |
| 975 | return true; |
| 976 | |
| 977 | // check the file attributes, note that if the file does not exist, |
| 978 | // this function returns false. that should be ok since we know |
| 979 | // the file system is writable at this point. |
| 980 | FileNode::Attributes attr; |
| 981 | if (getFileAttributes(path,&attr)) |
| 982 | return attr.flags & FileNode::ReadOnly; |
| 983 | return false; |
| 984 | } |
| 985 | |
| 986 | void MountSystem::startFileChangeNotifications() |
| 987 | { |
no test coverage detected