Commit 5a2e8356 authored by unknown's avatar unknown

Fixed access to uninitialized memory in protocol::store_time


BUILD/compile-pentium-valgrind-max:
  New attempt to avoid multiple warning
mysql-test/mysql-test-run.sh:
  --valgrind-all now automaticly enables valgrind
parent efb99e73
......@@ -14,7 +14,7 @@ extra_configs="$extra_configs --with-berkeley-db --with-innodb --without-isam --
if test -z "$just_print"
then
set +v
set +v +x
echo "\
******************************************************************************
Note that by default BUILD/compile-pentium-valgrind-max calls 'configure' with
......
......@@ -337,7 +337,7 @@ while test $# -gt 0; do
EXTRA_MASTER_MYSQLD_OPT="$EXTRA_MASTER_MYSQLD_OPT --gdb"
EXTRA_SLAVE_MYSQLD_OPT="$EXTRA_SLAVE_MYSQLD_OPT --gdb"
;;
--valgrind)
--valgrind | --valgrind-all)
VALGRIND=`which valgrind` # this will print an error if not found
# Give good warning to the user and stop
if [ -z "$VALGRIND" ] ; then
......@@ -350,14 +350,15 @@ while test $# -gt 0; do
SLEEP_TIME_AFTER_RESTART=10
SLEEP_TIME_FOR_DELETE=60
USE_RUNNING_SERVER=""
if test "$1" = "--valgrind-all"
then
VALGRIND="$VALGRIND -v --show-reachable=yes"
fi
;;
--valgrind-options=*)
TMP=`$ECHO "$1" | $SED -e "s;--valgrind-options=;;"`
VALGRIND="$VALGRIND $TMP"
;;
--valgrind-all)
VALGRIND="$VALGRIND -v --show-reachable=yes"
;;
--skip-*)
EXTRA_MASTER_MYSQLD_OPT="$EXTRA_MASTER_MYSQLD_OPT $1"
EXTRA_SLAVE_MYSQLD_OPT="$EXTRA_SLAVE_MYSQLD_OPT $1"
......
......@@ -779,7 +779,8 @@ bool str_to_time(const char *str,uint length,TIME *l_time)
current_thd->cuted_fields++;
return 1;
}
l_time->month=0;
l_time->year= 0; // For protocol::store_time
l_time->month= 0;
l_time->day= date[0];
l_time->hour= date[1];
l_time->minute= date[2];
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment