diff options
author | Bjorn Munch <Bjorn.Munch@sun.com> | 2009-08-19 13:48:56 +0200 |
---|---|---|
committer | Bjorn Munch <Bjorn.Munch@sun.com> | 2009-08-19 13:48:56 +0200 |
commit | d19eda4a9b59de353c9047376fd513bc0f5d69da (patch) | |
tree | d3f37096ded8a1901636025e9b444150cad638bd /client | |
parent | 4692054b182a9c64cdbb1a0a1a5f2f8af4e2ae5e (diff) | |
download | mariadb-git-d19eda4a9b59de353c9047376fd513bc0f5d69da.tar.gz |
Bug #39003 mtr's diff_files command failed in pushbuild without printing a result diff
diff was actually called but result never outputted before exiting
Added extra code to dump output *unless* failure was expected
Diffstat (limited to 'client')
-rw-r--r-- | client/mysqltest.cc | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/client/mysqltest.cc b/client/mysqltest.cc index a40ee1cd1d0..09b31599268 100644 --- a/client/mysqltest.cc +++ b/client/mysqltest.cc @@ -3440,12 +3440,17 @@ void do_diff_files(struct st_command *command) die("command \"diff_files\" failed, file '%s' does not exist", ds_filename2.str); - if ((error= compare_files(ds_filename.str, ds_filename2.str))) + if ((error= compare_files(ds_filename.str, ds_filename2.str)) && + match_expected_error(command, error, NULL) < 0) { /* Compare of the two files failed, append them to output - so the failure can be analyzed + so the failure can be analyzed, but only if it was not + expected to fail. */ show_diff(&ds_res, ds_filename.str, ds_filename2.str); + log_file.write(&ds_res); + log_file.flush(); + dynstr_set(&ds_res, 0); } dynstr_free(&ds_filename); |