mirror of
https://github.com/leozide/leocad
synced 2025-01-29 20:34:50 +01:00
Linux fixes.
This commit is contained in:
parent
e76cdc4e9c
commit
51ca702bb6
1 changed files with 7 additions and 6 deletions
|
@ -8,6 +8,7 @@
|
|||
#include "system.h"
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#include <ctype.h>
|
||||
|
||||
#define LC_LIBRARY_CACHE_VERSION 0x0100
|
||||
#define LC_LIBRARY_CACHE_ARCHIVE 0x0001
|
||||
|
@ -520,7 +521,7 @@ bool lcPiecesLibrary::OpenCache()
|
|||
{
|
||||
struct stat CacheStat;
|
||||
|
||||
if (stat(mCacheFileName, &CacheStat) != 0 || mCacheFileModifiedTime != CacheStat.st_mtime)
|
||||
if (stat(mCacheFileName, &CacheStat) != 0 || mCacheFileModifiedTime != (lcuint64)CacheStat.st_mtime)
|
||||
return false;
|
||||
|
||||
mCacheFile = new lcZipFile;
|
||||
|
@ -596,7 +597,7 @@ bool lcPiecesLibrary::LoadCachePiece(PieceInfo* Info)
|
|||
{
|
||||
struct stat CacheStat;
|
||||
|
||||
if (stat(mCacheFileName, &CacheStat) != 0 || mCacheFileModifiedTime != CacheStat.st_mtime)
|
||||
if (stat(mCacheFileName, &CacheStat) != 0 || mCacheFileModifiedTime != (lcuint64)CacheStat.st_mtime)
|
||||
return false;
|
||||
|
||||
lcZipFile CacheFile;
|
||||
|
@ -623,7 +624,7 @@ void lcPiecesLibrary::SaveCacheFile()
|
|||
if (!mSaveCache)
|
||||
return;
|
||||
|
||||
if (stat(mCacheFileName, &CacheStat) != 0 || mCacheFileModifiedTime != CacheStat.st_mtime)
|
||||
if (stat(mCacheFileName, &CacheStat) != 0 || mCacheFileModifiedTime != (lcuint64)CacheStat.st_mtime)
|
||||
{
|
||||
if (!CacheFile.OpenWrite(mCacheFileName, false))
|
||||
return;
|
||||
|
|
Loading…
Add table
Reference in a new issue