| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent bc2fbc7 commit 4bae2d5
7 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -34,7 +34,7 @@ This software comes with no warranty. Use at your own risk. | |||
| 34 | 34 | #include <windows.h> | |
| 35 | 35 | #endif | |
| 36 | 36 | ||
| 37 | - #if defined(__APPLE__) || defined(__MWERKS__) | ||
| 37 | + #if defined(__APPLE__) | ||
| 38 | 38 | #include "macglue.h" | |
| 39 | 39 | #endif | |
| 40 | 40 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -3,11 +3,6 @@ | |||
| 3 | 3 | ||
| 4 | 4 | #include "Python.h" | |
| 5 | 5 | ||
| 6 | - /* Mac with GUSI has more errors than those in errno.h */ | ||
| 7 | - #ifdef USE_GUSI | ||
| 8 | - #include <sys/errno.h> | ||
| 9 | - #endif | ||
| 10 | - | ||
| 11 | 6 | /* Windows socket errors (WSA*) */ | |
| 12 | 7 | #ifdef MS_WINDOWS | |
| 13 | 8 | #include <winsock.h> | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1739,11 +1739,6 @@ sock_makefile(PySocketSockObject *s, PyObject *args) | |||
| 1739 | 1739 | SOCKETCLOSE(fd); | |
| 1740 | 1740 | return s->errorhandler(); | |
| 1741 | 1741 | } | |
| 1742 | - #ifdef USE_GUSI2 | ||
| 1743 | - /* Workaround for bug in Metrowerks MSL vs. GUSI I/O library */ | ||
| 1744 | - if (strchr(mode, 'b') != NULL) | ||
| 1745 | - bufsize = 0; | ||
| 1746 | - #endif | ||
| 1747 | 1742 | f = PyFile_FromFile(fp, "<socket>", mode, fclose); | |
| 1748 | 1743 | if (f != NULL) | |
| 1749 | 1744 | PyFile_SetBufSize(f, bufsize); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -41,15 +41,6 @@ static PyObject *StructError; | |||
| 41 | 41 | ||
| 42 | 42 | /* Define various structs to figure out the alignments of types */ | |
| 43 | 43 | ||
| 44 | - #ifdef __MWERKS__ | ||
| 45 | - /* | ||
| 46 | - ** XXXX We have a problem here. There are no unique alignment rules | ||
| 47 | - ** on the PowerPC mac. | ||
| 48 | - */ | ||
| 49 | - #ifdef __powerc | ||
| 50 | - #pragma options align=mac68k | ||
| 51 | - #endif | ||
| 52 | - #endif /* __MWERKS__ */ | ||
| 53 | 44 | ||
| 54 | 45 | typedef struct { char c; short x; } st_short; | |
| 55 | 46 | typedef struct { char c; int x; } st_int; | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -21,17 +21,6 @@ | |||
| 21 | 21 | #include <windows.h> | |
| 22 | 22 | #endif /* _MSC_VER */ | |
| 23 | 23 | ||
| 24 | - #ifdef macintosh | ||
| 25 | - #ifdef USE_GUSI | ||
| 26 | - #define HAVE_FTRUNCATE | ||
| 27 | - #endif | ||
| 28 | - #endif | ||
| 29 | - | ||
| 30 | - #ifdef __MWERKS__ | ||
| 31 | - /* Mwerks fopen() doesn't always set errno */ | ||
| 32 | - #define NO_FOPEN_ERRNO | ||
| 33 | - #endif | ||
| 34 | - | ||
| 35 | 24 | #if defined(PYOS_OS2) && defined(PYCC_GCC) | |
| 36 | 25 | #include <io.h> | |
| 37 | 26 | #endif | |
@@ -209,18 +198,6 @@ open_the_file(PyFileObject *f, char *name, char *mode) | |||
| 209 | 198 | } | |
| 210 | 199 | } | |
| 211 | 200 | if (f->f_fp == NULL) { | |
| 212 | - #ifdef NO_FOPEN_ERRNO | ||
| 213 | - /* Metroworks only, wich does not always sets errno */ | ||
| 214 | - if (errno == 0) { | ||
| 215 | - PyObject *v; | ||
| 216 | - v = Py_BuildValue("(is)", 0, "Cannot open file"); | ||
| 217 | - if (v != NULL) { | ||
| 218 | - PyErr_SetObject(PyExc_IOError, v); | ||
| 219 | - Py_DECREF(v); | ||
| 220 | - } | ||
| 221 | - return NULL; | ||
| 222 | - } | ||
| 223 | - #endif | ||
| 224 | 201 | #ifdef _MSC_VER | |
| 225 | 202 | /* MSVC 6 (Microsoft) leaves errno at 0 for bad mode strings, | |
| 226 | 203 | * across all Windows flavors. When it sets EINVAL varies | |
@@ -739,12 +716,7 @@ new_buffersize(PyFileObject *f, size_t currentsize) | |||
| 739 | 716 | works. We can't use the lseek() value either, because we | |
| 740 | 717 | need to take the amount of buffered data into account. | |
| 741 | 718 | (Yet another reason why stdio stinks. :-) */ | |
| 742 | - #ifdef USE_GUSI2 | ||
| 743 | - pos = lseek(fileno(f->f_fp), 1L, SEEK_CUR); | ||
| 744 | - pos = lseek(fileno(f->f_fp), -1L, SEEK_CUR); | ||
| 745 | - #else | ||
| 746 | 719 | pos = lseek(fileno(f->f_fp), 0L, SEEK_CUR); | |
| 747 | - #endif | ||
| 748 | 720 | if (pos >= 0) { | |
| 749 | 721 | pos = ftell(f->f_fp); | |
| 750 | 722 | } | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -45,10 +45,6 @@ extern char *getenv(const char *); | |||
| 45 | 45 | #define SUN_LWP | |
| 46 | 46 | #endif | |
| 47 | 47 | ||
| 48 | - #if defined(__MWERKS__) && !defined(__BEOS__) | ||
| 49 | - #define _POSIX_THREADS | ||
| 50 | - #endif | ||
| 51 | - | ||
| 52 | 48 | #endif /* _POSIX_THREADS */ | |
| 53 | 49 | ||
| 54 | 50 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -68,14 +68,6 @@ | |||
| 68 | 68 | ||
| 69 | 69 | #endif | |
| 70 | 70 | ||
| 71 | - #ifdef USE_GUSI | ||
| 72 | - /* The Macintosh GUSI I/O library sets the stackspace to | ||
| 73 | - ** 20KB, much too low. We up it to 64K. | ||
| 74 | - */ | ||
| 75 | - #define THREAD_STACK_SIZE 0x10000 | ||
| 76 | - #endif | ||
| 77 | - | ||
| 78 | - | ||
| 79 | 71 | /* set default attribute object for different versions */ | |
| 80 | 72 | ||
| 81 | 73 | #if defined(PY_PTHREAD_D4) || defined(PY_PTHREAD_D7) | |
| Back | FazBrowse Home | New Git URL |
0 commit comments