List:Commits« Previous MessageNext Message »
From:Sanja Byelkin Date:November 14 2007 9:01am
Subject:Re: [Fwd: bk commit into 5.1 tree (gshchepa:1.2648) BUG#32034]
View as plain text  
Hi!

Patch is OK to push after fixing small thing.

(I hope you ran the test case with and without the find call fixed)

On Wed, Nov 14, 2007 at 12:52:39PM +0400, Gleb Shchepa wrote:
>
>
> -------- Original Message --------
> Subject: bk commit into 5.1 tree (gshchepa:1.2648) BUG#32034
> Date: Wed, 14 Nov 2007 01:29:24 +0400 (SAMT)
> From: <gshchepa@stripped>
> To: commits@stripped

[skip]

> diff -Nrup a/storage/example/ha_example.cc b/storage/example/ha_example.cc
> --- a/storage/example/ha_example.cc	2007-08-27 23:20:00 +05:00
> +++ b/storage/example/ha_example.cc	2007-11-14 01:23:17 +04:00
> @@ -848,6 +848,37 @@ int ha_example::create(const char *name,
>  struct st_mysql_storage_engine example_storage_engine=
>  { MYSQL_HANDLERTON_INTERFACE_VERSION };
>
> +
> +static ulong srv_enum_var= 0;
> +
> +const size_t enum_var_typelib_count= 2;
> +const char *enum_var_type_names[enum_var_typelib_count]    = { "e1", "e2" 
> };
> +unsigned int enum_var_type_lengths[enum_var_typelib_count] = {    2,   2  
> };
> +
> +TYPELIB enum_var_typelib =
> +{
> +  enum_var_typelib_count,
> +  "enum_var_typelib",
> +  enum_var_type_names,
> +  enum_var_type_lengths
> +};

IMHO there is more safe (for maintaning) way to declare such array so it
should be given as example:

const char *enum_var_names[]=
{
  "e1", "e2", NullS
};
TYPELIB enum_var__typelib=
{
  array_elements(enum_var_names) - 1, "enum_var_typelib",
  enum_var_names, NULL
};

[skip]

-- 
   __  ___     ___ ____  __
  /  |/  /_ __/ __/ __ \/ /    Mr. Oleksandr Byelkin <sanja@stripped>
 / /|_/ / // /\ \/ /_/ / /__   MySQL AB, Full-Time Developer
/_/  /_/\_, /___/\___\_\___/   Lugansk, Ukraine
       <___/   www.mysql.com
Thread
Re: [Fwd: bk commit into 5.1 tree (gshchepa:1.2648) BUG#32034]Sanja Byelkin14 Nov