Пример #1
0
static void compare_neighboring_leaves_in_pass1 (void)
{
    struct key * left = B_N_PKEY (g_left, B_NR_ITEMS (g_left) - 1);

    if (comp_keys (left, B_N_PKEY (g_right, 0)) != -1/*SECOND_GREATER*/)
	die ("compare_neighboring_leaves_in_pass1: left key is greater, that the right one");
    
    if (/*comp_keys (B_PRIGHT_DELIM_KEY (g_left), g_dkey) == FIRST_GREATER ||*/
	comp_keys (g_dkey, B_N_PKEY (g_right, 0))) {
	reiserfs_panic (0, "compare_neighboring_leaves_in_pass1: dkey %k, first key in right %k",
			g_dkey, B_N_PKEY (g_right, 0));
    }
    
    check_items (g_left);
    
    /*&&&&&&&&&&&&&&&&&&&&&&&&&&
      for (i = 0, ih = B_N_PITEM_HEAD (g_left, i); i < B_NR_ITEMS (g_left); i ++, ih ++)
      if (is_item_accessed (ih) == YES)
      die ("compare_neighboring_leaves_in_pass1: item marked as accessed in g_left");
      for (i = 0, ih = B_N_PITEM_HEAD (g_right, i); i < B_NR_ITEMS (g_right); i ++, ih ++)
      if (is_item_accessed (ih) == YES)
      die ("compare_neighboring_leaves_in_pass1: item marked as accessed in g_right");
      &&&&&&&&&&&&&&&&&&&&&&&&&&&*/
    
}
Пример #2
0
bool LASzip::check()
{
  if (!check_compressor(compressor)) return false;
  if (!check_coder(coder)) return false;
  if (!check_items(num_items, items)) return false;
  return true;
}
Пример #3
0
bool LASzip::setup(const U16 num_items, const LASitem* items, const U16 compressor)
{
  // check input
  if (!check_compressor(compressor)) return false;
  if (!check_items(num_items, items)) return false;

  // setup compressor
  this->compressor = compressor;
  if (this->compressor == LASZIP_COMPRESSOR_POINTWISE_CHUNKED)
  {
    if (chunk_size == 0) chunk_size = LASZIP_CHUNK_SIZE_DEFAULT;
  }

  // prepare items
  this->num_items = 0;
  if (this->items) delete [] this->items;
  this->items = 0;
  this->num_items = num_items;
  this->items = new LASitem[num_items];

  // setup items
  U16 i;
  for (i = 0; i < num_items; i++)
  {
    this->items[i] = items[i];
  }

  return true;
}
Пример #4
0
/**
* init_client(void)
*
* @brief Initializes client
* @param void
* @return void
*/
void init_client(void)
{
	printf("Initializing Data. \n");

	check_dir(LOG_PATH);
	check_tiles();
	check_sprites();
	check_items();
	check_spells();

	init_items();
	_sleep(100);
	init_maps();
	init_npcs();
	init_shops();
	init_spells();
	init_players();

	printf("Data Initialized. \n");
}