Tango 32 bit windows binaries crash when calling DeviceProxy::command_list_query()

0 views
Skip to first unread message

Max Gilljohann

unread,
Apr 6, 2016, 1:37:12 PM4/6/16
to ta...@esrf.fr
Hi,

while trying to compile labview bindings for 32 bit on Windows I encountered an error in DeviceProxy::command_list_query() (only) with the 32 bit binaries. It seems that the returned Tango::CommandInfoList* when calling command_list_query() on some DeviceProxy is somehow corrupted. To be more specific, a pointer to a vector of CommandInfo is returned, and only the cmd_name of the very first CommandInfo is what it's supposed to be, everything else (cmd_tag etc. and the other CommandInfos) is corrupted. The funny thing is when I debug the function, the CommandInfoList within the function command_list_query() seems okay, but as soon as debugging jumps back into the calling function the data is corrupted. Simply reading e.g. string or long attributes works fine. The debugger complains that the source file of the 9.2.2 source distribution is different from what the library was built but I don't know if this has anything to do with the problem.

I reproduced the problem on two different Windows machines with two different Visual Studio versions (2013 and 2015) and both 32 bit Windows binaries (the dll libs) of 9.2.2. With the 64 bit binaries everything works just fine.

The error "std::bad_alloc" occurs when calling

Tango::DeviceProxy dp("a/b/c");
Tango::CommandInfoList *cil = dp.command_list_query();
Tango::CommandInfo ci = (*cil)[0];

in the last step as soon as the CommandInfoList is accessed.

Does anyone have an idea what the problem might be?

Best regards,
Max

--
Max Gilljohann
Fakultät für Physik der LMU München
Am Coulombwall 1
85748 Garching, Germany

Room E30
Tel. +49-89-289-54046
Email max.gil...@physik.uni-muenchen.de



message-footer.txt

Emmanuel TAUREL

unread,
Apr 7, 2016, 11:09:49 AM4/7/16
to ta...@esrf.fr
Hi Max,

I have just tried on my old Windows 32 bits and I don't have problem. I
agree, this PC is very old (still running XP).
But take care, the provided 32 bits libraries are for VC9 (Visual Studio
2008) and VC10 (Visual Studio 2010).
This could be the reason of your problem.

Regards

Emmanuel
message-footer.txt

Max Gilljohann

unread,
May 17, 2016, 6:54:47 PM5/17/16
to ta...@esrf.fr
Hi Emmanuel,

thank you a lot for the quick response and sorry for my late one. You
were right, the problem seems to be the platformtoolset. I assumed that
the dlls are universal and work with various compilers, but I was wrong.
However, with the VC10 compiler (which fortunately integrates into
VS2015) it works and I was finally able to build the 32 bit version of
the 2.0.0 RC2 LabView binding from Nicolas Leclercq.

Whoever compiled the binaries for Windows, is there any possibility to
write a very short guide or a few words on how to compile Tango for
Windows? ZMQ and OmniOrb is documented elsewhere, but building Tango
from the Linux source without a guide is not that trivial (at least for
me). And being able to use all the C++11 features in 32 bit Windows
would be very convenient.

Best regards and thanks for all the great work on Tango,
Max
message-footer.txt
Reply all
Reply to author
Forward
0 new messages