Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-3626

LP:731815 - Crash/valgrind warning Item::send with 5.1-micro

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:

      Description

      Not repeatable with mysql-5.1.

      The following query

      SELECT CONVERT_TZ( TIMEDIFF( '0000-00-00 00:00:00' , f1 ) , 'UTC' , 'Europe/Moscow' ) FROM t1 ;

      causes a crash in Item::send, however GDB does not print a stacktrace. Valgrind reports:

      ==7458== Thread 3:
      ==7458== Invalid read of size 1
      ==7458== at 0x81B33B9: Item::send(Protocol*, String*) (item.cc:5695)
      ==7458== Address 0x33 is not stack'd, malloc'd or (recently) free'd
      ==7458==

      test case:

      CREATE TABLE t1 ( f1 timestamp NULL DEFAULT '0000-00-00 00:00:00');
      INSERT INTO t1 VALUES ('2007-06-25 21:00:00'),('2008-03-26 07:09:06');

      SELECT CONVERT_TZ( TIMEDIFF( '0000-00-00 00:00:00' , f1 ) , 'UTC' , 'Europe/Moscow' ) FROM t1 ;

        Gliffy Diagrams

          Attachments

            Activity

            Hide
            philipstoev Philip Stoev added a comment -

            Crash/valgrind warning Item::send with 5.1-micro
            The following query

            SELECT CONVERT_TZ( TIMEDIFF( '0000-00-00 00:00:00' , f1 ) , 'UTC' , 'Europe/Moscow' ) FROM t1 ;

            causes a crash in Item::send, however GDB does not print a stacktrace. Valgrind reports:

            ==7458== Thread 3:
            ==7458== Invalid read of size 1
            ==7458== at 0x81B33B9: Item::send(Protocol*, String*) (item.cc:5695)
            ==7458== Address 0x33 is not stack'd, malloc'd or (recently) free'd
            ==7458==

            test case:

            CREATE TABLE t1 ( f1 timestamp NULL DEFAULT '0000-00-00 00:00:00');
            INSERT INTO t1 VALUES ('2007-06-25 21:00:00'),('2008-03-26 07:09:06');

            SELECT CONVERT_TZ( TIMEDIFF( '0000-00-00 00:00:00' , f1 ) , 'UTC' , 'Europe/Moscow' ) FROM t1 ;

            Show
            philipstoev Philip Stoev added a comment - Crash/valgrind warning Item::send with 5.1-micro The following query SELECT CONVERT_TZ( TIMEDIFF( '0000-00-00 00:00:00' , f1 ) , 'UTC' , 'Europe/Moscow' ) FROM t1 ; causes a crash in Item::send, however GDB does not print a stacktrace. Valgrind reports: ==7458== Thread 3: ==7458== Invalid read of size 1 ==7458== at 0x81B33B9: Item::send(Protocol*, String*) (item.cc:5695) ==7458== Address 0x33 is not stack'd, malloc'd or (recently) free'd ==7458== test case: CREATE TABLE t1 ( f1 timestamp NULL DEFAULT '0000-00-00 00:00:00'); INSERT INTO t1 VALUES ('2007-06-25 21:00:00'),('2008-03-26 07:09:06'); SELECT CONVERT_TZ( TIMEDIFF( '0000-00-00 00:00:00' , f1 ) , 'UTC' , 'Europe/Moscow' ) FROM t1 ;
            Hide
            ratzpo Rasmus Johansson added a comment -

            Launchpad bug id: 731815

            Show
            ratzpo Rasmus Johansson added a comment - Launchpad bug id: 731815

              People

              • Assignee:
                serg Sergei Golubchik
                Reporter:
                philipstoev Philip Stoev
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: