[Python-checkins] python/dist/src/Modules socketmodule.c, 1.271.6.6, 1.271.6.7

aimacintyre at users.sourceforge.net aimacintyre at users.sourceforge.net
Sun Apr 11 08:10:05 EDT 2004


Update of /cvsroot/python/python/dist/src/Modules
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv589

Modified Files:
      Tag: release23-maint
	socketmodule.c 
Log Message:
Backport to 2.3:

Fixes for AF_UNIX support on OS/2:
- return the full size of the sockaddr_un structure, without which
  bind() fails with EINVAL;
- set test_socketserver to use a socket name that meets the form
  required by the underlying implementation;
- don't bother exercising the forking AF_UNIX tests on EMX - its
  fork() can't handle the stress.


Index: socketmodule.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Modules/socketmodule.c,v
retrieving revision 1.271.6.6
retrieving revision 1.271.6.7
diff -C2 -d -r1.271.6.6 -r1.271.6.7
*** socketmodule.c	4 Apr 2004 07:19:27 -0000	1.271.6.6
--- socketmodule.c	11 Apr 2004 12:10:03 -0000	1.271.6.7
***************
*** 951,955 ****
--- 951,959 ----
  		addr->sun_path[len] = 0;
  		*addr_ret = (struct sockaddr *) addr;
+ #if defined(PYOS_OS2)
+ 		*len_ret = sizeof(*addr);
+ #else
  		*len_ret = len + sizeof(*addr) - sizeof(addr->sun_path);
+ #endif
  		return 1;
  	}




More information about the Python-checkins mailing list