⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 allocate.c

📁 R+树的c实现源码
💻 C
字号:
#include <stdio.h>#include "macros.h"#include "options.h"#include "index.h"#include "global.h"#include "assert.h"/*-----------------------------------------------------------------------------| Space allocation routines. - just keep track of No. of allocations|| Call myalloc() like malloc().| Call myfree() like free().-----------------------------------------------------------------------------*/static	int	puse=0; vuse=0;static	int	all = 0;static	int	maxuse=0;char *myalloc(n)register int	 n;{	char	*malloc();	all++;	puse++;	if ((puse-vuse) > maxuse)		maxuse++;	return malloc(n);}myfree(p)char	*p;{	all--;	vuse++;	free(p);}myfreeOFN( p )register struct OverFlowNode 	*p;{    	register struct OverFlowNode 	*q;    	while ( p != NULL ) {		all --;		vuse++;		q = p->next2;		free(p);		p = q;    	}}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -