Plan 9 from Bell Labs’s /usr/web/sources/contrib/uriel/changes/2005/1206/8

Copyright © 2021 Plan 9 Foundation.
Distributed under the MIT License.
Download the Plan 9 distribution.


64-bit fix bug fix.
 [rsc] --rw-rw-r-- M 845139 glenda sys 1437 Dec  6 11:04 sys/src/cmd/sam/list.c
	/n/sourcesdump/2005/1206/plan9/sys/src/cmd/sam/list.c:16,22 - 
	/n/sourcesdump/2005/1207/plan9/sys/src/cmd/sam/list.c:16,22
	  	else if(l->nused == l->nalloc){
	  		p = erealloc(l->listptr, (l->nalloc+INCR)*esize);
	  		l->listptr = p;
	- 		memset(p+l->nalloc, 0, INCR*esize);
	+ 		memset(p+l->nalloc*esize, 0, INCR*esize);
	  		l->nalloc += INCR;
	  	}
	  }
 [rsc] --rw-rw-r-- M 845139 glenda sys 12016 Dec  6 11:05 sys/src/cmd/sam/sam.c
 [rsc] --rw-rw-r-- M 845139 glenda sys 9366 Dec  6 11:04 sys/src/cmd/sam/sam.h
	/n/sourcesdump/2005/1206/plan9/sys/src/cmd/sam/sam.h:66,77 - 
	/n/sourcesdump/2005/1207/plan9/sys/src/cmd/sam/sam.h:66,76
	  
	  struct List
	  {
	- 	int	type;
	+ 	int	type;	/* 'p' for pointer, 'P' for Posn */
	  	int	nalloc;
	  	int	nused;
	  	union{
	  		void*	listp;
	- 		Block*	blkp;
	  		void**	voidp;
	  		Posn*	posnp;
	  		String**stringp;


Bell Labs OSI certified Powered by Plan 9

(Return to Plan 9 Home Page)

Copyright © 2021 Plan 9 Foundation. All Rights Reserved.
Comments to webmaster@9p.io.