diff options
author | jimw@mysql.com <> | 2005-03-31 11:43:39 -0800 |
---|---|---|
committer | jimw@mysql.com <> | 2005-03-31 11:43:39 -0800 |
commit | e286515667d3cd3028092ef5c1277dff75d2ee21 (patch) | |
tree | 6c7a142119afeac5892dac907536f364b1834867 /client/mysqlcheck.c | |
parent | b5528a8dc6f85d20c13c5afbdfa23177ef1101d7 (diff) | |
download | mariadb-git-e286515667d3cd3028092ef5c1277dff75d2ee21.tar.gz |
Fix segmentation fault in mysqlcheck when the last table
checked with --auto-repair mode returned an error (such
as being a merge table). (Bug #9492)
Diffstat (limited to 'client/mysqlcheck.c')
-rw-r--r-- | client/mysqlcheck.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/client/mysqlcheck.c b/client/mysqlcheck.c index 8764611adf4..b5a80782948 100644 --- a/client/mysqlcheck.c +++ b/client/mysqlcheck.c @@ -537,6 +537,7 @@ static void print_result() my_bool found_error=0; res = mysql_use_result(sock); + prev[0] = '\0'; for (i = 0; (row = mysql_fetch_row(res)); i++) { @@ -565,7 +566,7 @@ static void print_result() putchar('\n'); } if (found_error && opt_auto_repair && what_to_do != DO_REPAIR && - (!opt_fast || strcmp(row[3],"OK"))) + !opt_fast) insert_dynamic(&tables4repair, prev); mysql_free_result(res); } |