Skip to content

Commit

Permalink
Unconditionally send gtid in SHOW BINARY LOGS WITH GTID
Browse files Browse the repository at this point in the history
Summary:
When the gtid is empty, nothing is sent over the wire to
the client. This was causing memory issues client side because the
client expects a fixed number of columns per row, and nothing was being sent.
Fix is to send an empty string in it's place.

squash with: 25fec83

Reviewed By: lth

Differential Revision: D4812840

fbshipit-source-id: 103dd4e
  • Loading branch information
abal147 authored and facebook-github-bot committed Mar 31, 2017
1 parent 86e7a21 commit ee92950
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions sql/rpl_master.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2712,6 +2712,8 @@ bool show_binlogs(THD* thd, bool with_gtid)
gtid_set.to_string(&buf, &Gtid_set::commented_string_format);
protocol->store(buf, strlen(buf), &my_charset_bin);
free(buf);
} else {
protocol->store("", 0, &my_charset_bin);
}
}

Expand Down

0 comments on commit ee92950

Please sign in to comment.