>>>>> "Yuri" == Yuri Dario <mc6530@stripped> writes:
Yuri> Hi Monty,
Yuri> this sounds not trivial for me: could you tell me where to work?
>> In sql/sql_table.cc:
>> int mysql_analyze_table(THD* thd, TABLE_LIST* tables, HA_CHECK_OPT* check_opt)
>> int mysql_check_table(THD* thd, TABLE_LIST* tables,HA_CHECK_OPT* check_opt)
>> For OS/2, you have to change TL_READ_NO_INSERT to TL_WRITE if you want
Yuri> I did that, and worked in most situations. But this one
Yuri> lock table t1 read
Yuri> check table t1
Yuri> hit the lock type check at open_ltable() line 1408. So I lowered the
Yuri> lock_type to TL_WRITE_ALLOW_WRITE to soddify the check.
Yuri> But this doesn't call my_lock() (with a WRLCK), so the file is still
There is never any reason to do a lock table before a check, so I
don't see this is a problem; We can just defined that for OS/2 you
have to do LOCK TABLE WRITE in this case.