[libbluray-devel] win32: do not re-define ftello and fseeko

hpi1 git at videolan.org
Thu Oct 10 08:57:22 CEST 2013


libbluray | branch: master | hpi1 <hpi1 at anonymous.org> | Thu Oct 10 09:54:05 2013 +0300| [3044e6cd9e57c55de11ba71bcc81c5f9e1818bc1] | committer: hpi1

win32: do not re-define ftello and fseeko

> http://git.videolan.org/gitweb.cgi/libbluray.git/?a=commit;h=3044e6cd9e57c55de11ba71bcc81c5f9e1818bc1
---

 src/file/file_posix.c |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/file/file_posix.c b/src/file/file_posix.c
index 11bf5bd..fec26ab 100644
--- a/src/file/file_posix.c
+++ b/src/file/file_posix.c
@@ -37,8 +37,6 @@
 
 #ifdef _WIN32
 #include <windows.h>
-#define	ftello	_ftelli64
-#define	fseeko	_fseeki64
 #endif	//	#ifdef _WIN32
 
 static void file_close_linux(BD_FILE_H *file)
@@ -56,6 +54,8 @@ static int64_t file_seek_linux(BD_FILE_H *file, int64_t offset, int32_t origin)
 {
 #if defined(__MINGW32__)
     return fseeko64((FILE *)file->internal, offset, origin);
+#elif defined(_WIN32)
+    return _fseeki64((FILE *)file->internal, offset, origin);
 #else
     return fseeko((FILE *)file->internal, offset, origin);
 #endif
@@ -65,6 +65,8 @@ static int64_t file_tell_linux(BD_FILE_H *file)
 {
 #if defined(__MINGW32__)
     return ftello64((FILE *)file->internal);
+#elif defined(_WIN32)
+    return _ftelli64((FILE *)file->internal);
 #else
     return ftello((FILE *)file->internal);
 #endif



More information about the libbluray-devel mailing list