mirror of
https://github.com/glest/glest-source.git
synced 2025-08-26 01:23:35 +02:00
- added purge file stats and bugfix when showing help on commandline
This commit is contained in:
@@ -1433,10 +1433,12 @@ bool renameFile(string oldFile, string newFile) {
|
||||
return (result == 0);
|
||||
}
|
||||
|
||||
long getFileSize(string filename) {
|
||||
off_t getFileSize(string filename) {
|
||||
struct stat stbuf;
|
||||
stat(filename.c_str(), &stbuf);
|
||||
return stbuf.st_size;
|
||||
if(stat(filename.c_str(), &stbuf) != -1) {
|
||||
return stbuf.st_size;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
// =====================================
|
||||
|
Reference in New Issue
Block a user