Пример #1
0
void sev_repair::clean()
{
  int i;

  printf( " \n-- Number of tables to clean: %u\n", m_db->m_items.size());
  for ( i = 0; i < (int)m_db->m_items.size(); i++) {
    clean_item( i, 1);
  }
}
Пример #2
0
void sev_repair::clean( char *table)
{
  int found = 0;

  for ( unsigned int i = 0; i < m_db->m_items.size(); i++) {
    if ( cdh_NoCaseStrcmp( table, m_db->m_items[i].tablename) == 0) {
      clean_item(i, 0);
      found = 1;
      break;
    }
  }
  if ( !found)
    printf( "** No such table\n");
  else
    printf( "-- Table successfully cleaned\n");
}
Пример #3
0
static int process_item(Item *i) {
        int r, q, p;

        assert(i);

        r = arg_create ? create_item(i) : 0;
        q = arg_remove ? remove_item(i) : 0;
        p = arg_clean ? clean_item(i) : 0;

        if (r < 0)
                return r;

        if (q < 0)
                return q;

        return p;
}