Page MenuHomeDevCentral

Conditional jump or move depends on uninitialised value(s) in mq_connect
Open, Needs TriagePublic

Description

IMPORTANT: This scenario should be repro with a debug version of the library.

When using in TCL mq connect <host>:

Without providing credentials
$ valgrind --track-origins=yes tclsh
==24487== Memcheck, a memory error detector
==24487== Copyright (C) 2002-2013, and GNU GPL'd, by Julian Seward et al.
==24487== Using Valgrind-3.10.1 and LibVEX; rerun with -h for copyright info
==24487== Command: tclsh
==24487== 
% load /home/surfboard/rabbitmq.so
% mq connected
0
% mq connect localhost
Can't connect to the broker.
% mq connect white-rabbit.nasqueron.org 
==24487== Conditional jump or move depends on uninitialised value(s)
==24487==    at 0x6618EDE: ??? (in /usr/local/lib/librabbitmq.so.4.1.3)
==24487==    by 0x6618D9C: amqp_login (in /usr/local/lib/librabbitmq.so.4.1.3)
==24487==    by 0x6406FEC: mq_connect (rabbitmq-tcl.c:366)
==24487==    by 0x64067DD: call_mq_command (rabbitmq-tcl.c:263)
==24487==    by 0x6408020: mq_command (rabbitmq-tcl.c:234)

==24487==  Uninitialised value was created by a stack allocation
==24487==    at 0x6618DBD: ??? (in /usr/local/lib/librabbitmq.so.4.1.3)
==24487== 
==24487== Conditional jump or move depends on uninitialised value(s)
==24487==    at 0x66194D7: ??? (in /usr/local/lib/librabbitmq.so.4.1.3)
==24487==    by 0x6618D9C: amqp_login (in /usr/local/lib/librabbitmq.so.4.1.3)
==24487==    by 0x6406FEC: mq_connect (rabbitmq-tcl.c:366)
==24487==    by 0x64067DD: call_mq_command (rabbitmq-tcl.c:263)
==24487==    by 0x6408020: mq_command (rabbitmq-tcl.c:234)

==24487==  Uninitialised value was created by a stack allocation
==24487==    at 0x6618DB6: ??? (in /usr/local/lib/librabbitmq.so.4.1.3)
==24487== 
Can't login to the broker.
With correct credentials
$ valgrind ./eggdrop-1.8.0 -nt Oberon/eggdrop.conf
[...]
.tcl source scripts/Wearg/Broker.tcl
.tcl source scripts/Wearg/Notifications.tcl
.tcl broker::init
==24002== Conditional jump or move depends on uninitialised value(s)
==24002==    at 0x9E06EDE: ??? (in /usr/local/lib/librabbitmq.so.4.1.3)
==24002==    by 0x9E06D9C: amqp_login (in /usr/local/lib/librabbitmq.so.4.1.3)
==24002==    by 0x9BF4FEC: mq_connect (rabbitmq-tcl.c:366)
==24002==    by 0x9BF47DD: call_mq_command (rabbitmq-tcl.c:263)
==24002==    by 0x9BF6020: mq_command (rabbitmq-tcl.c:234)

==24002== 
==24002== Conditional jump or move depends on uninitialised value(s)
==24002==    at 0x9E074D7: ??? (in /usr/local/lib/librabbitmq.so.4.1.3)
==24002==    by 0x9E06D9C: amqp_login (in /usr/local/lib/librabbitmq.so.4.1.3)
==24002==    by 0x9BF4FEC: mq_connect (rabbitmq-tcl.c:366)
==24002==    by 0x9BF47DD: call_mq_command (rabbitmq-tcl.c:263)
==24002==    by 0x9BF6020: mq_command (rabbitmq-tcl.c:234)
NOTE: Error occurs only once per interpreter.

Event Timeline

dereckson created this task.Sep 9 2016, 21:16
dereckson updated the task description. (Show Details)
dereckson renamed this task from Conditional jump or move depends on uninitialised value(s) in amqp_login to Conditional jump or move depends on uninitialised value(s) in mq_connect.Sep 9 2016, 21:20
dereckson updated the task description. (Show Details)Sep 9 2016, 21:30
dereckson updated the task description. (Show Details)Sep 9 2016, 21:37
dereckson updated the task description. (Show Details)Sep 9 2016, 21:43