[Valgrind] Conditional jump or move depends on uninitialised value on setTransform()



  • Hi, i create a function in a QGraphicsPixmapItem class for rotate on Y axis my object.
    Valgrind says to me Conditional jump or move depends on uninitialised value on this line
    @
    setTransform(QTransform().translate(icon.width()/2 ,icon.height()/2).rotate(v,Qt::YAxis).translate(-icon.width()/2 ,-icon.height()/2), false);
    @

    v is a parameter of function.
    Anybody know the problem?



  • Valgrind is known to give some false positives for Qt. There are suppression files that contain the known ones. If you find a valgrind issue that is not in those files, please report it.

    One way of testing this is to use the new Qt Creator that has the Analysis function build in. That one uses valgrind and the suppression files I mentioned.



  • New Qt Creator mean 2.4.0?

    [quote author="Andre" date="1322039224"]Valgrind is known to give some false positives for Qt. There are suppression files that contain the known ones. If you find a valgrind issue that is not in those files, please report it.

    One way of testing this is to use the new Qt Creator that has the Analysis function build in. That one uses valgrind and the suppression files I mentioned. [/quote]



  • I think so, yes. I have spotted it in some version, but I am not at a system where I can check which version that is exactly.



  • I have a 2.3.1 with analyzer option. But i can't find the suppression files to add.
    Do you remember where it located?

    [quote author="Andre" date="1322039701"]I think so, yes. I have spotted it in some version, but I am not at a system where I can check which version that is exactly. [/quote]



  • For the build-in analyzer, they should be used automatically.



  • Mmm i try 2.4.0 but nothing change.
    Is there a method to know what suppression rules is used?

    [quote author="Andre" date="1322041126"]For the build-in analyzer, they should be used automatically. [/quote]



  • I don't know that, sorry! And perhaps you just stumbled on a real issue that is not in the suppression files... I suggest you fire up your IRC client, connect to the freenode network, and drop into the #qt-labs channel. You can discuss the issue with Qt engineers there.





  • Ah, I am very sorry. I misread your initial post, and thought that the line you posted was in the code of Qt itself, instead of in your own code. That is why I thought you might have stumbled on a (Qt) bug, and you should head into #qt-labs and all the stuff about valgrind suppression lists.

    Those lists are of course never going to apply to your own code. They are not magical :-)

    Again, I apologize for sending you down the wrong track on this one.

    As to why Valgrind tells you what it does: sorry, I don't know. That would require disecting your code to see what really happens there in detail. I'm afraid that that is your puzzle to make...



  • Ok, thanks to help.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.