projects
/
platform
/
upstream
/
flac.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix a couple of Windows 2Gig file size issues.
[platform/upstream/flac.git]
/
src
/
share
/
grabbag
/
file.c
diff --git
a/src/share/grabbag/file.c
b/src/share/grabbag/file.c
index
a95cd3f
..
04e3aad
100644
(file)
--- a/
src/share/grabbag/file.c
+++ b/
src/share/grabbag/file.c
@@
-61,11
+61,17
@@
void grabbag__file_copy_metadata(const char *srcpath, const char *destpath)
}
}
}
}
-off_t grabbag__file_get_filesize(const char *srcpath)
+
FLAC__
off_t grabbag__file_get_filesize(const char *srcpath)
{
{
+#if defined _MSC_VER || defined __MINGW32__
+ struct _stat64 srcstat;
+
+ if(0 == _stat64(srcpath, &srcstat))
+#else
struct stat srcstat;
if(0 == stat(srcpath, &srcstat))
struct stat srcstat;
if(0 == stat(srcpath, &srcstat))
+#endif
return srcstat.st_size;
else
return -1;
return srcstat.st_size;
else
return -1;