diff options
author | unknown <tnurnberg@mysql.com/white.intern.koehntopp.de> | 2007-12-17 12:09:21 +0100 |
---|---|---|
committer | unknown <tnurnberg@mysql.com/white.intern.koehntopp.de> | 2007-12-17 12:09:21 +0100 |
commit | ef7c445101671cea2eaf4a2c67617ebbaab323ce (patch) | |
tree | c5cda5347590ad284ad9074555d85d07875b28a2 /client | |
parent | 14e9797ebd94329ba98f845d28451faf5353410e (diff) | |
download | mariadb-git-ef7c445101671cea2eaf4a2c67617ebbaab323ce.tar.gz |
Bug#31752: check strmake() bounds
fix test program
client/mysqltest.c:
fix buffer off-by-ones in test program
Diffstat (limited to 'client')
-rw-r--r-- | client/mysqltest.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/client/mysqltest.c b/client/mysqltest.c index 04dfce28ab4..d5a03961364 100644 --- a/client/mysqltest.c +++ b/client/mysqltest.c @@ -3067,7 +3067,7 @@ void do_get_file_name(struct st_command *command, if (*p) *p++= 0; command->last_argument= p; - strmake(dest, name, dest_max_len); + strmake(dest, name, dest_max_len - 1); } @@ -6375,7 +6375,7 @@ int main(int argc, char **argv) if (save_file[0]) { - strmake(command->require_file, save_file, sizeof(save_file)); + strmake(command->require_file, save_file, sizeof(save_file) - 1); save_file[0]= 0; } run_query(cur_con, command, flags); |