Plan 9 from Bell Labs’s /usr/web/sources/contrib/uriel/changes/2005/0922/19

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


Call a pointer a pointer.
 [jmk] --rw-rw-r-- M 191333 glenda sys 1796 Sep 22 17:48 sys/src/cmd/vt/consctl.c
	/n/sourcesdump/2005/0922/plan9/sys/src/cmd/vt/consctl.c:10,24 - 
	/n/sourcesdump/2005/0923/plan9/sys/src/cmd/vt/consctl.c:10,25
	  static void*
	  share(int len)
	  {
	- 	ulong vastart;
	+ 	uchar *vastart;
	  
	- 	vastart = ((ulong)sbrk(0)) + 2*1024*1024;
	+ 	vastart = sbrk(0);
	+ 	vastart += 2*1024*1024;
	  
	- 	if(segattach(0, "shared", (void *)vastart, len) < 0)
	+ 	if(segattach(0, "shared", vastart, len) < 0)
	  		return 0;
	- 	memset((void*)vastart, 0, len);
	+ 	memset(vastart, 0, len);
	  
	- 	return (void*)vastart;
	+ 	return vastart;
	  }
	  
	  /*
 [sys] --rwxrwxr-x M 191333 glenda sys 173660 Sep 22 23:10 386/bin/vt
	/sys/src/cmd/vt/consctl.c:share


Bell Labs OSI certified Powered by Plan 9

(Return to Plan 9 Home Page)

Copyright © 2021 Plan 9 Foundation. All Rights Reserved.
Comments to [email protected].