my_datetime_to_str: Conditional jump or move depends on uninitialised value

Description

Run "valgrind --tool=memcheck mysqld" and execute this SQL query:

Valgrind reports uninitialized memory read.
It seems str_to_datetime() does not handle this case well
and leaves the "second_part" member of the "l_time"
argument uninitialized.

This is the valgrind report:

Valgrind reports no problems with TIME.

The second part of the original report has been moved to

The patch merging SQL standard temporal literals (from MySQL-5.6) fixed this problem.

Environment

None

Status

Assignee

Alexander Barkov

Reporter

Alexander Barkov

Labels

None

External issue ID

None

External issue ID

None

Fix versions

Affects versions

Priority

Critical
Configure