Beispiel #1
0
////////////////////////////////////////////////////////////
// Push down any data from the old tree onto the new tree 
// by doing a traversal over the deleted clusters
//////////////////////////////////////////////////////////
void pushDown(cluster* cl)
{   
  cluster* ccl;
  int i;
  assert(cl);
 
  ccl = GET_CL(cl);  
  deprintf("pushDown: cl = %d\n",ccl->id);
 
  cluster** clusters = ccl->getClusters();
  for(i=0; i < MAX_DEGREE; ++i)
    {
      cluster* child = clusters[i];
      cluster* ccp = GET_CL(child);
      if(child) {
	pushDownFun(ccl,ccp);
	if(isDeleted(ccp)) {
	  if(ccp->child) {
	    deprintf("Child\n");
	    pushDown(child);
	    deprintf("ret\n");
	  }
	  freeCluster(ccp);
	}
      }
    }
  free(clusters);     
}
Beispiel #2
0
void						clusterMain()
{
	cluster_t				pcluster;
	
	initCluster(&pcluster);
	//if (checkVersion() == I_FALSE)
	//	fatalError(L"This version of Windows is not supported for Windows Clustering.");
	if (checkClusterState() == I_FALSE)
		exit(1);
	getClusterGroups(&pcluster);
	generateReport(&pcluster);
	freeCluster(&pcluster);
}