diff options
author | unknown <jani@rhols221.adsl.netsonic.fi> | 2003-12-16 11:44:22 +0200 |
---|---|---|
committer | unknown <jani@rhols221.adsl.netsonic.fi> | 2003-12-16 11:44:22 +0200 |
commit | c46989003ba893e7664efc944b39462a25bda61b (patch) | |
tree | 0f66fb3a7866b1b591916b6d91a607a4e0f380f0 /client | |
parent | 2b3e2821c7c275cd026e7916587c8373acc9c231 (diff) | |
download | mariadb-git-c46989003ba893e7664efc944b39462a25bda61b.tar.gz |
Some minor code clean up.
Diffstat (limited to 'client')
-rw-r--r-- | client/mysqltest.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/client/mysqltest.c b/client/mysqltest.c index a53e259c726..08b58f1ccfe 100644 --- a/client/mysqltest.c +++ b/client/mysqltest.c @@ -1630,7 +1630,7 @@ int do_while(struct st_query* q) my_bool end_of_query(int c, char* p) { - uint i= 0, j; + uint i, j; int tmp[MAX_DELIMITER]= {0}; for (i= 0; c == *(delimiter + i) && i < delimiter_length; @@ -1642,7 +1642,7 @@ my_bool end_of_query(int c, char* p) ungetc(tmp[j], *cur_file); if (i == delimiter_length) { - ungetc(tmp[j], *cur_file); + ungetc(tmp[i], *cur_file); *p= 0; return 1; } @@ -2189,7 +2189,7 @@ int run_query(MYSQL* mysql, struct st_query* q, int flags) { replace_dynstr_append_mem(ds,query, query_len); sprintf(buff, "%s\n", delimiter); - dynstr_append_mem(ds, buff, strlen(delimiter) + 1); + dynstr_append_mem(ds, buff, delimiter_length + 1); } if (!(flags & QUERY_REAP)) DBUG_RETURN(0); |