Bug #78379 valgrind warning in mysqltest with --ps-protocol
Submitted: 9 Sep 2015 10:41 Modified: 9 Sep 2015 15:51
Reporter: Tor Didriksen Email Updates:
Status: Closed Impact on me:
None 
Category:Tests Severity:S3 (Non-critical)
Version:5.7 OS:Any
Assigned to: CPU Architecture:Any

[9 Sep 2015 10:41] Tor Didriksen
Description:
==13732== Conditional jump or move depends on uninitialised value(s)
==13732==    at 0x41B0A2: run_query_stmt(st_mysql*, st_command*, char*, unsigned long, st_dynamic_string*, st_dynamic_string*) (mysqltest.cc:8208)
==13732==    by 0x41BA68: run_query(st_connection*, st_command*, int) (mysqltest.cc:8506)
==13732==    by 0x41D9FD: main (mysqltest.cc:9389)

How to repeat:
$./mtr --mem --ps-protocol --valgrind type_newdecimal

Suggested fix:
Initialize local variables.
[9 Sep 2015 13:47] Tor Didriksen
Posted by developer:
 
Note that earlier versions have the same bug,
it's just mtr that does not detect it.
The patch for
    Bug#21672747 ADD MTR OPTION TO RUN ALL CLIENT APPLICATIONS WITH VALGRIND
added --error-exitcode=42 to the valgrind flags.
That's why mtr picks up the error in 5.7 and 5.8
[9 Sep 2015 15:51] Jon Stephens
Fixed in 5.7.9+.

Affects testing only, no user-facing changes to be documented.

Closed.