Overview
Comment: | Use 64 bit file offsets |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA3-256: |
c409a0ec954848ccea2395940b335eaf |
User & Date: | js on 2015-01-17 22:41:00 |
Other Links: | manifest | tags |
Context
2015-01-19
| ||
22:29 | OFStream: writeBufferEnabled -> writeBuffered check-in: afb42d363d user: js tags: trunk | |
2015-01-17
| ||
22:41 | Use 64 bit file offsets check-in: c409a0ec95 user: js tags: trunk | |
18:39 | Fix compilation on Win32 check-in: 8b0caeabde user: js tags: trunk | |
Changes
Modified configure.ac from [fb80735dec] to [073f94a1b8].
︙ | |||
691 692 693 694 695 696 697 698 699 700 701 702 703 704 | 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 | + + + + | AC_ARG_ENABLE(files, AS_HELP_STRING([--disable-files], [disable file support])) AS_IF([test x"$enable_files" != x"no"], [ AC_DEFINE(OF_HAVE_FILES, 1, [Whether we have files]) AC_SUBST(USE_SRCS_FILES, '${SRCS_FILES}') AC_SUBST(OFHASH, "ofhash") AC_SUBST(OFZIP, "ofzip") AC_CHECK_TYPE(off64_t, [ AC_DEFINE(OF_HAVE_OFF64_T, 1, [Whether we have off64_t]) ]) AC_CHECK_FUNCS(readdir_r) ]) AC_CHECK_FUNCS([sysconf gmtime_r localtime_r nanosleep lstat]) AC_CHECK_HEADERS([pwd.h grp.h]) |
︙ |
Modified src/OFFile.h from [de974a9641] to [ea93239d94].
︙ | |||
25 26 27 28 29 30 31 | 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 | - - + + + + - + | #include <sys/stat.h> #import "OFSeekableStream.h" @class OFArray; @class OFDate; |
︙ |
Modified src/OFFile.m from [73987ccc68] to [864c3ff8dd].
︙ | |||
122 123 124 125 126 127 128 | 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 | - - + + + + + - + + + + + + + + + + + | #if !defined(HAVE_READDIR_R) && !defined(_WIN32) && defined(OF_HAVE_THREADS) static of_mutex_t mutex; #endif int of_stat(OFString *path, of_stat_t *buffer) { |
︙ | |||
891 892 893 894 895 896 897 | 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 | - - + + + + + - - + + | int flags; if ((flags = parseMode([mode UTF8String])) == -1) @throw [OFInvalidArgumentException exception]; flags |= O_CLOEXEC; |
︙ | |||
973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 | 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 | + + + + + + | requestedLength: length]; #endif } - (of_offset_t)lowlevelSeekToOffset: (of_offset_t)offset whence: (int)whence { #if defined(_WIN32) of_offset_t ret = _lseeki64(_fd, offset, whence); #elif defined(OF_HAVE_OFF64_T) of_offset_t ret = lseek64(_fd, offset, whence); #else of_offset_t ret = lseek(_fd, offset, whence); #endif if (ret == -1) @throw [OFSeekFailedException exceptionWithStream: self offset: offset whence: whence]; _atEndOfStream = false; |
︙ |
Modified src/OFSeekableStream.h from [56c089ffb2] to [2c45e50707].
︙ | |||
21 22 23 24 25 26 27 | 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | + + - + + + | # define __STDC_CONSTANT_MACROS #endif #include <sys/types.h> #import "OFStream.h" #if defined(_WIN32) typedef __int64 of_offset_t; |
︙ |