Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(3)

Side by Side Diff: Modules/_io/fileio.c

Issue 3871: cross and native build of python for mingw32 with distutils
Patch Set: Created 7 years, 2 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Modules/getnameinfo.c ('k') | Modules/_localemodule.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* Author: Daniel Stutzbach */ 1 /* Author: Daniel Stutzbach */
2 2
3 #define PY_SSIZE_T_CLEAN 3 #define PY_SSIZE_T_CLEAN
4 #include "Python.h" 4 #include "Python.h"
5 #include "structmember.h" 5 #include "structmember.h"
6 #ifdef HAVE_SYS_TYPES_H 6 #ifdef HAVE_SYS_TYPES_H
7 #include <sys/types.h> 7 #include <sys/types.h>
8 #endif 8 #endif
9 #ifdef HAVE_SYS_STAT_H 9 #ifdef HAVE_SYS_STAT_H
10 #include <sys/stat.h> 10 #include <sys/stat.h>
(...skipping 12 matching lines...) Expand all
23 * - Passing numbers greater than 2**32-1 when an integer is expected 23 * - Passing numbers greater than 2**32-1 when an integer is expected
24 * - Making it work on Windows and other oddball platforms 24 * - Making it work on Windows and other oddball platforms
25 * 25 *
26 * To Do: 26 * To Do:
27 * 27 *
28 * - autoconfify header file inclusion 28 * - autoconfify header file inclusion
29 */ 29 */
30 30
31 #ifdef MS_WINDOWS 31 #ifdef MS_WINDOWS
32 /* can simulate truncate with Win32 API functions; see file_truncate */ 32 /* can simulate truncate with Win32 API functions; see file_truncate */
33 #ifndef HAVE_FTRUNCATE
33 #define HAVE_FTRUNCATE 34 #define HAVE_FTRUNCATE
35 #endif
34 #define WIN32_LEAN_AND_MEAN 36 #define WIN32_LEAN_AND_MEAN
35 #include <windows.h> 37 #include <windows.h>
36 #endif 38 #endif
37 39
38 #if BUFSIZ < (8*1024) 40 #if BUFSIZ < (8*1024)
39 #define SMALLCHUNK (8*1024) 41 #define SMALLCHUNK (8*1024)
40 #elif (BUFSIZ >= (2 << 25)) 42 #elif (BUFSIZ >= (2 << 25))
41 #error "unreasonable BUFSIZ > 64MB defined" 43 #error "unreasonable BUFSIZ > 64MB defined"
42 #else 44 #else
43 #define SMALLCHUNK BUFSIZ 45 #define SMALLCHUNK BUFSIZ
(...skipping 1183 matching lines...) Expand 10 before | Expand all | Expand 10 after
1227 0, /* tp_base */ 1229 0, /* tp_base */
1228 0, /* tp_dict */ 1230 0, /* tp_dict */
1229 0, /* tp_descr_get */ 1231 0, /* tp_descr_get */
1230 0, /* tp_descr_set */ 1232 0, /* tp_descr_set */
1231 offsetof(fileio, dict), /* tp_dictoffset */ 1233 offsetof(fileio, dict), /* tp_dictoffset */
1232 fileio_init, /* tp_init */ 1234 fileio_init, /* tp_init */
1233 PyType_GenericAlloc, /* tp_alloc */ 1235 PyType_GenericAlloc, /* tp_alloc */
1234 fileio_new, /* tp_new */ 1236 fileio_new, /* tp_new */
1235 PyObject_GC_Del, /* tp_free */ 1237 PyObject_GC_Del, /* tp_free */
1236 }; 1238 };
OLDNEW
« no previous file with comments | « Modules/getnameinfo.c ('k') | Modules/_localemodule.c » ('j') | no next file with comments »

RSS Feeds Recent Issues | This issue
This is Rietveld 894c83f36cb7+