diff options
author | tomas@poseidon.ndb.mysql.com <> | 2005-10-07 01:12:46 +0200 |
---|---|---|
committer | tomas@poseidon.ndb.mysql.com <> | 2005-10-07 01:12:46 +0200 |
commit | e72fdf56194b529b14696bbb0b743e25eefb7f0e (patch) | |
tree | 73ff186be5c6524a0a96e1d6359b8f58263b7a4c /extra/perror.c | |
parent | 3703570c9c8a1040ad66dc4d933dcaa9a0e767b4 (diff) | |
parent | 38fd830f9e7fc4f239a5a3acb40354cc49e7b5e9 (diff) | |
download | mariadb-git-e72fdf56194b529b14696bbb0b743e25eefb7f0e.tar.gz |
Merge
Diffstat (limited to 'extra/perror.c')
-rw-r--r-- | extra/perror.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/extra/perror.c b/extra/perror.c index 551dc3096d4..06a42c5ec06 100644 --- a/extra/perror.c +++ b/extra/perror.c @@ -25,6 +25,7 @@ #include <my_getopt.h> #ifdef HAVE_NDBCLUSTER_DB #include "../storage/ndb/src/ndbapi/ndberror.c" +#include "../storage/ndb/src/kernel/error/ndbd_exit_codes.c" #endif static my_bool verbose, print_all_codes; @@ -235,8 +236,11 @@ int main(int argc,char *argv[]) #ifdef HAVE_NDBCLUSTER_DB if (ndb_code) { - if (ndb_error_string(code, ndb_string, sizeof(ndb_string)) < 0) - msg= 0; + if ((ndb_error_string(code, ndb_string, sizeof(ndb_string)) < 0) && + (ndbd_exit_string(code, ndb_string, sizeof(ndb_string)) < 0)) + { + msg= 0; + } else msg= ndb_string; } |