diff options
author | Michael Widenius <monty@askmonty.org> | 2010-07-17 01:57:55 +0300 |
---|---|---|
committer | Michael Widenius <monty@askmonty.org> | 2010-07-17 01:57:55 +0300 |
commit | f58199f6f6b4795ab5d0db65ebdde8bd4897333e (patch) | |
tree | 8817e17ed4d7ad710531c811d1d5df2138514f47 /client | |
parent | 178f18467e3b2e69fdbdce19c21041bc6fcd0e77 (diff) | |
parent | 24c08f5279ff350495d7334dcecd470a3c88cefb (diff) | |
download | mariadb-git-f58199f6f6b4795ab5d0db65ebdde8bd4897333e.tar.gz |
Merge with MariaDB 5.1
Diffstat (limited to 'client')
-rw-r--r-- | client/mysql.cc | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/client/mysql.cc b/client/mysql.cc index 161a82a8089..db3da9dcbdb 100644 --- a/client/mysql.cc +++ b/client/mysql.cc @@ -1,5 +1,6 @@ -/* Copyright (C) 2000-2009 MySQL AB & Monty Program Ab +/* Copyright (C) 2000-2009 MySQL AB Copyright 2000, 2010, Oracle and/or its affiliates. All rights reserved. + Copyright 2000-2010 Monty Program Ab This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -15,7 +16,6 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #define COPYRIGHT_NOTICE "\ -Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.\n\ This software comes with ABSOLUTELY NO WARRANTY. This is free software,\n\ and you are welcome to modify and redistribute it under the GPL v2 license\n" @@ -2220,9 +2220,12 @@ static bool add_line(String &buffer,char *line,char *in_string, the line -- which would occur only because of the user sending newline -- which is itself whitespace and should also match. + We also ignore lines starting with '--', even if there + isn't a whitespace after. (This makes it easier to run + mysql-test-run cases through the client) */ - (my_isspace(charset_info,pos[2]) || - !pos[2]))))) + ((my_isspace(charset_info,pos[2]) || !pos[2]) || + (buffer.is_empty() && out == line)))))) { // Flush previously accepted characters if (out != line) |