Comment 3 for bug 432210

Revision history for this message
fmpwizard (diego-fmpwizard) wrote :

Hi Padraig!

Thanks for looking into this.

This is something else I have found so far:

1- I start drizzled and I then start the client under gdb with a breakpoint on
client/drizzle.cc

static void build_completion_hash(bool rehash, bool write_info)

And I looked at "databases", I then restart drizzled and send
"use test;"
when I print databases, note the line with:

field = 0x6d7b1 <Address 0x6d7b1 out of bounds>

I was wondering if there was a way to "reset" databases to a "clean" state once we are here.

Thanks

-Diego

(gdb) run
Starting program: /Applications/mysql/enterprise/drizzle-local/bin/drizzle -p3306 -h192.168.0.99
warning: posix_spawn failed, trying execvp, error: 86

Breakpoint 1, build_completion_hash (rehash=true, write_info=true) at client/drizzle.cc:2429
2429 COMMANDS *cmd=commands;
(gdb) print databases
$4 = {
  con = 0x7fff5fbfe820,
  next = 0x1000a5bf0,
  prev = 0x5fbfe820,
  options = 446912,
  info = "\001", '\0' <repeats 11 times>, "@####\000\000\000\000\000\000\000\000\000\000@####\000\000\020####\000\000}3\n\000\001", '\0' <repeats 11 times>, "##\006\000\001\000\000\000##\006\000\001", '\0' <repeats 1974 times>,
  error_code = 0,
  sqlstate = "\000\000\000\000\000",
  insert_id = 0,
  warning_count = 0,
  affected_rows = 0,
  column_count = 0,
  column_current = 0,
  column_list = 0x0,
  column = 0x0,
  column_buffer = 0x0,
  row_count = 0,
  row_current = 0,
  field_current = 0,
  field_total = 0,
  field_offset = 0,
  field_size = 0,
  field = 0x0,
  field_buffer = 0x0,
  row_list_size = 0,
  row = 0x0,
  row_list = 0x0,
  field_sizes = 0x0,
  field_sizes_list = 0x0
}
(gdb) c
Continuing.
Welcome to the Drizzle client.. Commands end with ; or \g.
Your Drizzle connection id is 2
Server version: 2009.09.1127 Source distribution (local-trunk)

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

<<<< Right here I restarted drizzled >>>>>

drizzle> use test;

Breakpoint 1, build_completion_hash (rehash=true, write_info=true) at client/drizzle.cc:2429
2429 COMMANDS *cmd=commands;
(gdb) print databases
$5 = {
  con = 0x0,
  next = 0x0,
  prev = 0x0,
  options = DRIZZLE_RESULT_NONE,
  info = '\0' <repeats 2047 times>,
  error_code = 0,
  sqlstate = "\000\000\000\000\000",
  insert_id = 4295414208,
  warning_count = 58416,
  affected_rows = 4295621717,
  column_count = 4,
  column_current = 0,
  column_list = 0x0,
  column = 0x7fff5fbfe45c,
  column_buffer = 0x10006d1c0,
  row_count = 0,
  row_current = 72057598332895233,
  field_current = 58480,
  field_total = 4295646192,
  field_offset = 0,
  field_size = 4295414208,
  field = 0x6d7b1 <Address 0x6d7b1 out of bounds>,
  field_buffer = 0x0,
  row_list_size = 4297457664,
  row = 0x1,
  row_list = 0x5,
  field_sizes = 0x0,
  field_sizes_list = 0x7fff5fbfe4c0
}
(gdb)