Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

#22 Uninitialized variable in quadratics.cpp

open
nobody
None
5
2011-04-11
2011-04-11
John Bollinger
No

Static code analysis detects use of an uninitialized vector (Pend) by CToroid::sample in computing its transform. It looks like the problem might arise from a cut & paste error, and on that assumption I have inferred from context what the correct code probably should be. If I have characterized the error correctly then the erroneous code also clobbers a different vector that it had previously initialized. I attach a patch.

Note that if I have characterized the problem incorrectly, then the patch may create breakage.

Discussion

  • Eibriel
    Eibriel
    2011-04-11

    Thanks again! I'll take a look.

     
  • Natacha
    Natacha
    2011-04-12

    I run into issues (which look like completely random geometry) almost every time I try to use a toroid primitive that is hit by raytraced rays. It's a recurring issue, which I reported and was theoretically fixed twice, so I kinda lost hope and crafted a nurbs providing the same geometry instead.

    I would be very glad if this solved the toroid issue.