diff options
author | Thomas Wouters <thomas@python.org> | 2000-07-24 16:06:23 (GMT) |
---|---|---|
committer | Thomas Wouters <thomas@python.org> | 2000-07-24 16:06:23 (GMT) |
commit | 1e0c2f4bee43728930bd5f4dc77283f09c4ba004 (patch) | |
tree | 230e982075e5b0804e08d8fd24e73373dfffeb8a /Modules/socketmodule.c | |
parent | 332c59c4efafd7b1f841dd144fa3843c8476de6e (diff) | |
download | cpython-1e0c2f4bee43728930bd5f4dc77283f09c4ba004.zip cpython-1e0c2f4bee43728930bd5f4dc77283f09c4ba004.tar.gz cpython-1e0c2f4bee43728930bd5f4dc77283f09c4ba004.tar.bz2 |
Create a new section of pyport.h to hold all external function declarations
for systems that are missing those declarations from system include files.
Start by moving a pointy-haired ones from their previous locations to the
new section.
(The gethostname() one, for instance, breaks on several systems, because
some define it as (char *, size_t) and some as (char *, int).)
I purposely decided not to include the summary of used #defines like Tim did
in the first section of pyport.h. In my opinion, the number of #defines
likedly to be used by this section would make such an overview unwieldy. I
would suggest documenting the non-obvious ones, though.
Diffstat (limited to 'Modules/socketmodule.c')
-rw-r--r-- | Modules/socketmodule.c | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/Modules/socketmodule.c b/Modules/socketmodule.c index 914931f..a9bfb26 100644 --- a/Modules/socketmodule.c +++ b/Modules/socketmodule.c @@ -110,10 +110,6 @@ Socket methods: #include <unistd.h> #endif -#if !defined(MS_WINDOWS) && !defined(PYOS_OS2) && !defined(__BEOS__) -extern int gethostname(char *, size_t); /* For Solaris, at least */ -#endif - #if defined(PYCC_VACPP) #include <types.h> #include <io.h> @@ -129,11 +125,6 @@ extern int gethostname(char *, size_t); /* For Solaris, at least */ #include <os2.h> #endif -#if defined(__BEOS__) -/* It's in the libs, but not the headers... - [cjh] */ -int shutdown( int, int ); -#endif - #include <sys/types.h> #include "mytime.h" @@ -2407,9 +2398,9 @@ shutdown() -- shut down traffic in one or both directions\n\ DL_EXPORT(void) #if defined(MS_WINDOWS) || defined(PYOS_OS2) || defined(__BEOS__) -init_socket() +init_socket(void) #else -initsocket() +initsocket(void) #endif { PyObject *m, *d; |