equal
deleted
inserted
replaced
1 This patch provides extended file stdio support. |
1 This patch provides extended file stdio support. |
2 As it is Solaris-specific, it is not suitable for upstream. |
2 As it is Solaris-specific, it is not suitable for upstream. |
3 |
3 |
4 --- Python-2.7.1/Modules/python.c.orig Tue Jun 21 21:35:45 2011 |
4 --- Python-2.7.12/Modules/python.c.~1~ 2016-06-25 14:49:31.000000000 -0700 |
5 +++ Python-2.7.1/Modules/python.c Tue Jun 21 21:39:29 2011 |
5 +++ Python-2.7.12/Modules/python.c 2016-07-07 13:39:38.170867069 -0700 |
6 @@ -6,6 +6,13 @@ |
6 @@ -6,6 +6,13 @@ |
7 #include <floatingpoint.h> |
7 #include <fenv.h> |
8 #endif |
8 #endif |
9 |
9 |
10 +#if defined(sun) && defined(__SVR4) && !defined(_LP64) |
10 +#if defined(sun) && defined(__SVR4) && !defined(_LP64) |
11 +#define USE_EXTENDED_FILE_STDIO 1 |
11 +#define USE_EXTENDED_FILE_STDIO 1 |
12 +#include <stdio.h> |
12 +#include <stdio.h> |
15 +#endif |
15 +#endif |
16 + |
16 + |
17 int |
17 int |
18 main(int argc, char **argv) |
18 main(int argc, char **argv) |
19 { |
19 { |
20 @@ -20,5 +27,18 @@ |
20 @@ -17,5 +24,18 @@ |
21 m = fpgetmask(); |
21 #ifdef __FreeBSD__ |
22 fpsetmask(m & ~FP_X_OFL); |
22 fedisableexcept(FE_OVERFLOW); |
23 #endif |
23 #endif |
24 +#ifdef USE_EXTENDED_FILE_STDIO |
24 +#ifdef USE_EXTENDED_FILE_STDIO |
25 + /* |
25 + /* |
26 + * enable extended FILE facility on Solaris so that Python |
26 + * enable extended FILE facility on Solaris so that Python |
27 + * apps can keep more than 256 file descriptors open |
27 + * apps can keep more than 256 file descriptors open |