X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Fsupport%2FFileInfo.C;h=49b7ba2c21ba4cc50f88af5d724cb7d1b0c23fc0;hb=33a28bdc9cdf978601d5d40b693f13924801ad9e;hp=1d2b9b88f4097f862db55551fe75c2cc4d7eb307;hpb=4b2a999762c83627476428e595d3c1e3704a3da0;p=lyx.git diff --git a/src/support/FileInfo.C b/src/support/FileInfo.C index 1d2b9b88f4..49b7ba2c21 100644 --- a/src/support/FileInfo.C +++ b/src/support/FileInfo.C @@ -1,11 +1,10 @@ -// -*- C++ -*- /* This file is part of * ====================================================== * * LyX, The Document Processor * * Copyright 1995 Matthias Ettrich - * Copyright 1995-2000 The LyX Team. + * Copyright 1995-2001 The LyX Team. * * ====================================================== */ @@ -15,8 +14,9 @@ #pragma implementation #endif -#include -#include +//#include +//#include + #include #include "FileInfo.h" @@ -140,9 +140,9 @@ void FileInfo::init() void FileInfo::dostat(bool link) { if (link) { - status = lstat(fname.c_str(), &buf); + status = ::lstat(fname.c_str(), &buf); } else { - status = stat(fname.c_str(), &buf); + status = ::stat(fname.c_str(), &buf); } if (status) err = errno; } @@ -237,7 +237,7 @@ char FileInfo::typeLetter() const // should not be in FileInfo -void FileInfo::flagRWX(unsigned short i, char * szString) const +void FileInfo::flagRWX(mode_t i, char * szString) const { szString[0] = (i & S_IRUSR) ? 'r' : '-'; szString[1] = (i & S_IWUSR) ? 'w' : '-'; @@ -373,7 +373,7 @@ bool FileInfo::isSocket() const // should not be in FileInfo -bool FileInfo::access(int p) +bool FileInfo::access(int p) const { // if we don't have a filename we fail if (fname.empty()) return false; @@ -386,3 +386,6 @@ bool FileInfo::access(int p) return false; } } + + +