~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/handler.cc

Merged trunk.

Show diffs side-by-side

added added

removed removed

Lines of Context:
2692
2692
    We cache the table flags if the locking succeeded. Otherwise, we
2693
2693
    keep them as they were when they were fetched in ha_open().
2694
2694
  */
2695
 
  DRIZZLE_EXTERNAL_LOCK(lock_type);
2696
2695
 
2697
2696
  int error= external_lock(session, lock_type);
 
2697
 
2698
2698
  if (error == 0)
2699
2699
    cached_table_flags= table_flags();
2700
2700
  return error;
2725
2725
int handler::ha_write_row(unsigned char *buf)
2726
2726
{
2727
2727
  int error;
2728
 
  DRIZZLE_INSERT_ROW_START();
2729
2728
 
2730
2729
  /* 
2731
2730
   * If we have a timestamp column, update it to the current time 
2739
2738
  mark_trx_read_write();
2740
2739
 
2741
2740
  if (unlikely(error= write_row(buf)))
 
2741
  {
2742
2742
    return error;
 
2743
  }
2743
2744
 
2744
2745
  if (unlikely(log_row_for_replication(table, 0, buf)))
2745
 
    return HA_ERR_RBR_LOGGING_FAILED; /* purecov: inspected */
 
2746
    return HA_ERR_RBR_LOGGING_FAILED;
2746
2747
 
2747
 
  DRIZZLE_INSERT_ROW_END();
2748
2748
  return 0;
2749
2749
}
2750
2750
 
2762
2762
  mark_trx_read_write();
2763
2763
 
2764
2764
  if (unlikely(error= update_row(old_data, new_data)))
 
2765
  {
2765
2766
    return error;
 
2767
  }
2766
2768
 
2767
2769
  if (unlikely(log_row_for_replication(table, old_data, new_data)))
2768
2770
    return HA_ERR_RBR_LOGGING_FAILED;