~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to storage/blackhole/ha_blackhole.cc

update to latest from trunk

Show diffs side-by-side

added added

removed removed

Lines of Context:
121
121
  return(0);
122
122
}
123
123
 
124
 
int ha_blackhole::external_lock(THD *thd __attribute__((unused)),
 
124
int ha_blackhole::external_lock(Session *session __attribute__((unused)),
125
125
                                int lock_type __attribute__((unused)))
126
126
{
127
127
  return(0);
128
128
}
129
129
 
130
130
 
131
 
THR_LOCK_DATA **ha_blackhole::store_lock(THD *thd,
 
131
THR_LOCK_DATA **ha_blackhole::store_lock(Session *session,
132
132
                                         THR_LOCK_DATA **to,
133
133
                                         enum thr_lock_type lock_type)
134
134
{
142
142
    */
143
143
 
144
144
    if ((lock_type >= TL_WRITE_CONCURRENT_INSERT &&
145
 
         lock_type <= TL_WRITE) && !thd_in_lock_tables(thd)
146
 
        && !thd_tablespace_op(thd))
 
145
         lock_type <= TL_WRITE) && !session_in_lock_tables(session)
 
146
        && !session_tablespace_op(session))
147
147
      lock_type = TL_WRITE_ALLOW_WRITE;
148
148
 
149
149
    /*
154
154
      concurrent inserts to t2.
155
155
    */
156
156
 
157
 
    if (lock_type == TL_READ_NO_INSERT && !thd_in_lock_tables(thd))
 
157
    if (lock_type == TL_READ_NO_INSERT && !session_in_lock_tables(session))
158
158
      lock_type = TL_READ;
159
159
 
160
160
    lock.type= lock_type;