[Python-checkins] CVS: python/dist/src/Objects fileobject.c,2.101,2.102

Tim Peters python-dev@python.org
Sun, 07 Jan 2001 20:02:09 -0800


Update of /cvsroot/python/python/dist/src/Objects
In directory usw-pr-cvs1:/tmp/cvs-serv27389/python/dist/src/objects

Modified Files:
	fileobject.c 
Log Message:
A few reformats; no logic changes.


Index: fileobject.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Objects/fileobject.c,v
retrieving revision 2.101
retrieving revision 2.102
diff -C2 -r2.101 -r2.102
*** fileobject.c	2001/01/08 01:26:47	2.101
--- fileobject.c	2001/01/08 04:02:07	2.102
***************
*** 640,649 ****
  Under MSVC 6:
  
! + MS threadsafe getc is very slow (multiple layers of function calls
!   before+after each character, to lock+unlock the stream).
! + The stream-locking functions are MS-internal -- can't access them
!   from user code.
! + There's nothing Tim could find in the MS C or platform SDK libraries
!   that can worm around this.
  + MS fgets locks/unlocks only once per line; it's the only hook we have.
  
--- 640,649 ----
  Under MSVC 6:
  
! + MS threadsafe getc is very slow (multiple layers of function calls before+
!   after each character, to lock+unlock the stream).
! + The stream-locking functions are MS-internal -- can't access them from user
!   code.
! + There's nothing Tim could find in the MS C or platform SDK libraries that
!   can worm around this.
  + MS fgets locks/unlocks only once per line; it's the only hook we have.
  
***************
*** 732,741 ****
  	/* yuck:  fgets overwrote all the newlines, i.e. the entire buffer.
  	 * So this line isn't over yet, or maybe it is but we're exactly at
! 	 *EOF; in either case, we're tired <wink>.
  	 */
  	assert(msbuf[INITBUFSIZE-1] == '\0');
  	total_v_size = INITBUFSIZE + INCBUFSIZE;
! 	v = PyString_FromStringAndSize((char*)NULL,
! 		(int)total_v_size);
  	if (v == NULL)
  		return v;
--- 732,740 ----
  	/* yuck:  fgets overwrote all the newlines, i.e. the entire buffer.
  	 * So this line isn't over yet, or maybe it is but we're exactly at
! 	 * EOF; in either case, we're tired <wink>.
  	 */
  	assert(msbuf[INITBUFSIZE-1] == '\0');
  	total_v_size = INITBUFSIZE + INCBUFSIZE;
! 	v = PyString_FromStringAndSize((char*)NULL, (int)total_v_size);
  	if (v == NULL)
  		return v;