~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/lock.cc

  • Committer: Monty Taylor
  • Date: 2008-09-23 14:19:48 UTC
  • mto: This revision was merged to the branch mainline in revision 419.
  • Revision ID: monty@inaugust.com-20080923141948-ktph2kg13addaxq1
Actually removed VOID() this time.

Show diffs side-by-side

added added

removed removed

Lines of Context:
230
230
    if (rc > 1)                                 /* a timeout or a deadlock */
231
231
    {
232
232
      if (sql_lock->table_count)
233
 
        VOID(unlock_external(thd, sql_lock->table, sql_lock->table_count));
 
233
        unlock_external(thd, sql_lock->table, sql_lock->table_count);
234
234
      reset_lock_data_and_free(&sql_lock);
235
235
      my_error(rc, MYF(0));
236
236
      break;
262
262
        thr_multi_unlock(sql_lock->locks, sql_lock->lock_count);
263
263
 
264
264
    if (sql_lock->table_count)
265
 
      VOID(unlock_external(thd, sql_lock->table, sql_lock->table_count));
 
265
      unlock_external(thd, sql_lock->table, sql_lock->table_count);
266
266
 
267
267
    /*
268
268
      If thr_multi_lock fails it resets lock type for tables, which
334
334
  if (sql_lock->lock_count)
335
335
    thr_multi_unlock(sql_lock->locks,sql_lock->lock_count);
336
336
  if (sql_lock->table_count)
337
 
    VOID(unlock_external(thd,sql_lock->table,sql_lock->table_count));
 
337
    unlock_external(thd,sql_lock->table,sql_lock->table_count);
338
338
  my_free((uchar*) sql_lock,MYF(0));
339
339
  return;
340
340
}
397
397
  /* Unlock all read locked tables */
398
398
  if (i != found)
399
399
  {
400
 
    VOID(unlock_external(thd,table,i-found));
 
400
    unlock_external(thd,table,i-found);
401
401
    sql_lock->table_count=found;
402
402
  }
403
403
  /* Fix the lock positions in Table */
861
861
 
862
862
  if (wait_if_global_read_lock(thd, 0, 1))
863
863
    return(1);
864
 
  VOID(pthread_mutex_lock(&LOCK_open));
 
864
  pthread_mutex_lock(&LOCK_open);
865
865
  if ((lock_retcode = lock_table_name(thd, table_list, true)) < 0)
866
866
    goto end;
867
867
  if (lock_retcode && wait_for_locked_table_names(thd, table_list))
1483
1483
 
1484
1484
void broadcast_refresh(void)
1485
1485
{
1486
 
  VOID(pthread_cond_broadcast(&COND_refresh));
1487
 
  VOID(pthread_cond_broadcast(&COND_global_read_lock));
 
1486
  pthread_cond_broadcast(&COND_refresh);
 
1487
  pthread_cond_broadcast(&COND_global_read_lock);
1488
1488
}
1489
1489
 
1490
1490