From: Zardosht Kasheff Date: July 24 2010 3:14am Subject: Re: [feedback/review request] Re: index creation and concurrent reads List-Archive: http://lists.mysql.com/internals/37996 Message-Id: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hello Davi, Is ALTER_KEYS_ONOFF set if and only if alter_info->keys_onoff is either ENABLE or DISABLE? -Zardosht On Fri, Jul 23, 2010 at 10:47 PM, Davi Arnaut wrot= e: > On 7/23/10 10:45 PM, Zardosht Kasheff wrote: >> >> Hello all, >> >> After some investigation, I think the attached patch solves the issue. >> I am interested in hearing feedback on the patch. >> > > How about: > > =3D=3D=3D modified file 'sql/sql_table.cc' > --- sql/sql_table.cc =A0 =A0(foo) > +++ sql/sql_table.cc =A0 =A0(bar) > @@ -7280,7 +7280,7 @@ view_err: > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 a= lter_info->keys_onoff, > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 a= lter_info->error_if_not_empty); > =A0 } > - =A0else > + =A0else if (alter_info->flags & ALTER_KEYS_ONOFF) > =A0 { > =A0 =A0 VOID(pthread_mutex_lock(&LOCK_open)); > =A0 =A0 wait_while_table_is_used(thd, table, HA_EXTRA_FORCE_REOPEN); > >