X-Git-Url: http://git.tdb.fi/?p=libs%2Fcore.git;a=blobdiff_plain;f=source%2Ffs%2Fstat.cpp;h=ccd344b875e809ecdbf3016e96d4576ab0c898dc;hp=1dc46db78289dce316ffb36bee60b3a9539066e2;hb=19edaf3b45bc4c23459fc8ddd552dcfa33eecc71;hpb=af94bc926e301e9b871dc18662b4fa6e5614fdbf diff --git a/source/fs/stat.cpp b/source/fs/stat.cpp index 1dc46db..ccd344b 100644 --- a/source/fs/stat.cpp +++ b/source/fs/stat.cpp @@ -1,15 +1,7 @@ -/* $Id$ - -This file is part of libmspfs -Copyright © 2006-2008 Mikko Rasa, Mikkosoft Productions -Distributed under the LGPL -*/ - -#include #ifdef WIN32 #include #endif -#include +#include #include "path.h" #include "stat.h" @@ -25,7 +17,7 @@ struct stat stat(const Path &fn) { struct stat st; if(stat(fn, st)==-1) - throw SystemError("stat failed", errno); + throw system_error("stat"); return st; } @@ -42,7 +34,7 @@ struct stat lstat(const Path &fn) { struct stat st; if(lstat(fn, st)==-1) - throw SystemError("lstat failed", errno); + throw system_error("lstat"); return st; }