List:Commits« Previous MessageNext Message »
From:Konstantin Osipov Date:October 23 2008 1:59pm
Subject:Re: bzr commit into mysql-6.0 branch (magne.mahre:2739) Bug#37433
View as plain text  
* Magne Mahre <Magne.Mahre@stripped> [08/10/23 15:26]:
>  2739 Magne Mahre	2008-10-23
>       Fixed Bug #37433 Deadlock between open_table, 
>       close_open_tables, get_table_share, drop_open_table
> modified:
>   sql/sql_db.cc

Please explain how the fix works in the changeset comment.
Thanks.

> === modified file 'sql/sql_db.cc'
> --- a/sql/sql_db.cc	2008-09-30 13:31:41 +0000
> +++ b/sql/sql_db.cc	2008-10-23 11:19:32 +0000
> @@ -2001,6 +2001,7 @@
>  {
>    char db_dir_path[FN_REFLEN];
>    uint db_dir_path_len;
> +  MY_STAT my_stat_result;
>  
>    db_dir_path_len= build_table_filename(db_dir_path, sizeof(db_dir_path),
>                                          db_name, "", "", 0);
> @@ -2008,6 +2009,14 @@
>    if (db_dir_path_len && db_dir_path[db_dir_path_len - 1] == FN_LIBCHAR)
>      db_dir_path[db_dir_path_len - 1]= 0;
>  
> +  /* Verify db_name is a directory */
> +
> +  if (! my_stat(db_dir_path, &my_stat_result, MYF(0)))
> +    return TRUE;
> +
> +  if (! MY_S_ISDIR(my_stat_result.st_mode))
> +    return TRUE;
> +
>    /* Check access. */
>  
>    return my_access(db_dir_path, F_OK);

-- 
Thread
bzr commit into mysql-6.0 branch (magne.mahre:2739) Bug#37433Magne Mahre23 Oct
  • Re: bzr commit into mysql-6.0 branch (magne.mahre:2739) Bug#37433Konstantin Osipov23 Oct