In my code, I have a class called membrane with a function called exciteMod() , named decide() and a variable called delta_U . The first line of exciteMod() is this->delta_U = 0 . In decide() has the exponent -delta_U ( exp(-this->delta_U) ). that cause the error. Using an uninitialized size value of 8. What can cause this? I have no errors in delta_U that is generated in valgrind.
Edit: Here is the corresponding code segment:
void membrane::exciteMod(){ this->delta_U = 0; std::tr1::shared_ptr<bead> bit = this->beads.begin(); while (bit != this->nead.end()){ std::tr1::shared_ptr<bead> b = *bit++;
This is a warning:
== 467 == Using an uninitialized value of size 8
== 467 == at 0x300B00D75D: __ieee754_exp (in / lib64 / libm-2.5.so)
== 467 == by 0x300B022FA3: exp (in / lib64 / libm-2.5.so)
== 467 == by 0x40BB9A: membrane :: solve () (membr.cpp: 813)
== 467 == by 0x40EBB1: membrane :: exciteMod () (membr.cpp: 639)
== 467 == by 0x413994: membrane :: MCstep (int) (membr.cpp: 486)
== 467 == by 0x402767: main (main.cpp: 14)
Edit:
I should have mentioned that the only place I call decide() is inside exciteMod() .
Yotam source share