Commit f8e02a29 authored by unknown's avatar unknown
Browse files

Replace the --exec in a while loop that causes 3400 executions of cygwin/bash on

windows with a small perl script that does exactly the same. 

parent d3cb7a68
Loading
Loading
Loading
Loading
+14 −11
Original line number Diff line number Diff line
@@ -145,21 +145,24 @@ drop table t1;
#
# Bug #19216: Client crashes on long SELECT
#
--exec echo "select" > $MYSQLTEST_VARDIR/tmp/b19216.tmp
# 3400 * 20 makes 68000 columns that is more than the max number that can fit 
# in a 16 bit number.
let $i= 3400;
while ($i)
{
  --exec echo "'a','a','a','a','a','a','a','a','a','a','a','a','a','a','a','a','a','a','a','a'," >> $MYSQLTEST_VARDIR/tmp/b19216.tmp
  dec $i;
}

--exec echo "'b';" >> $MYSQLTEST_VARDIR/tmp/b19216.tmp
# Create large SELECT
# - 3400 * 20 makes 68000 columns that is more than the
#   max number that can fit in a 16 bit number.

--perl
open(FILE,">","$ENV{'MYSQLTEST_VARDIR'}/tmp/b19216.tmp") or die;
print FILE "select\n";
print FILE "'a','a','a','a','a','a','a','a','a','a','a','a','a','a','a','a','a','a','a','a',\n" x 3400;
print FILE "'b';\n";
close FILE;
EOF

--disable_query_log
--exec $MYSQL < $MYSQLTEST_VARDIR/tmp/b19216.tmp >/dev/null
--enable_query_log

--remove_file $MYSQLTEST_VARDIR/tmp/b19216.tmp

#
# Bug #20103: Escaping with backslash does not work
#