certi-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[certi-dev] Memory issues


From: David Come
Subject: [certi-dev] Memory issues
Date: Thu, 27 Aug 2015 19:02:30 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.1.0

Hi.

I have just found some code try to access some uninitialized bytes
Please find attached is the valgrind dump.

I have had a look at libHLA/MessageBuffer.cc and I'm concerned about the code safety with the strict aliasing rule. See https://channel9.msdn.com/Events/CPP/C-PP-Con-2014/Lightning-Talks-The-Perils-of-Strict-Aliasing for strict aliasing rule.
and http://dbp-consulting.com/tutorials/StrictAliasing.html

There are also many hard coded magic numbers...


I also mention I encountered another bug when using isAttributeOwnedByFederate. In libRTI/hla-1_3/RTIambassador.cc, in RTI::RTIambassador::isAttributeOwnedByFederate
the rep.getTag()  gives me "RTI_TRUE0" at some point.

I can reproduce the bug, I'll try to figure it tomorrow.
I'm not sure if that issue is linked to the strict aliasing rule

David.

Attachment: valgrindDump
Description: Text document


reply via email to

[Prev in Thread] Current Thread [Next in Thread]