PDA

View Full Version : Qt 4.1.0 to 4.1.4 problem



^NyAw^
16th October 2007, 18:30
Hi,

I'm having problems porting my application from Qt 4.1.0 to 4.1.4.

I have a custom class that have 3 widgets. There is a method to hide all and other to show all like a unique widget.

My program do a lot of things when it is initalising and it call the method "hide" a lot of times. When it is called the program crash.

Any idea that if it is a bug? Thanks,

Note that it don't cause me problems executing it in Qt 4.1.0

I'm using Windows XP, Qt 4.1.4 and Visual Studio 2003 .NET

ToddAtWSU
16th October 2007, 18:37
Can you provide any code to show us where the crash is occurring. It sound like to me you have an invalid pointer somewhere, and maybe in 4.1.0 hide( ) didn't behave quite properly and they fixed it in 4.1.4 and now you just need to fix your code too. But showing us some code would help greatly, and if you could tell us which line exactly is causing the crash, that would be even better. Using Visual Studio, this should be easy to do. Thanks!

^NyAw^
16th October 2007, 18:57
Hi,

Sorry but I can't send you my code.

The pointers are ok, I have created them into constructor.
My class constructor recives the main widget and it creates a QLabel that have the main widget as its parent.

Thanks,

ToddAtWSU
16th October 2007, 19:34
Sorry but I don't think I will be able to help without seeing some code. We don't want all of it, just a little snippet. Hopefully somebody else will have an idea.

^NyAw^
17th October 2007, 13:00
Hi,

Is there any known problem using Visual Studio 2003 .NET and Qt 4.1.4?
I'm using Qt 4.1.4 commercial edition (vs2005). Have I to recompile Qt with "QMAKESPEC" set to "win32-msvc.net"?

Thanks,

jpn
20th October 2007, 20:54
Could you show us the callstack from Visual Studio by the time of crash?

^NyAw^
22nd October 2007, 10:35
Hi,

sorry for delay. I had uninstalled Qt 4.1.0 and Qt 4.1.4 and reinstalled Qt 4.1.0 again. I'm going to continue using Qt 4.1.0 for now.
Sorry, but I can't try to install Qt 4.1.4 and compile my progrogram because I'm having a lot of work to do this days. Maybe will try it in a few weeks.

Thanks for replies,

wysota
22nd October 2007, 11:35
Of course you are familiar with the fact that Qt 4.1 is very outdated and you should consider installing Qt 4.3.2? It takes only 15 minutes, so I doubt your work will suffer. But of course the choice is yours.

^NyAw^
22nd October 2007, 11:51
Hi,

Will try, but now I can't. I have to give a working copy of the program as soon as possible and I can't spend time.

Thanks,

wysota
22nd October 2007, 11:59
Just take into consideration that your application might be using a buggy behaviour of the software which might have been fixed in a more recent release (like 4.1.4) and your code will break again causing you to fix the more code the later you decide to do it. You are using an uninitialized pointer somewhere probably and the backtrace would quickly reveal the problem allowing it to be fixed instantly.

Good luck with your deadline.

^NyAw^
23rd October 2007, 17:52
Hi,
I have installed Qt 4.3 now. I'm having the same problem so ... let's try to check it.


Could you show us the callstack from Visual Studio by the time of crash?

How I can show you this? by a screenshot? I have upoaded it.

Thanks,

^NyAw^
23rd October 2007, 18:25
Hi,

Finally I've found the error. I use a QGridLayout into the MainWindow and then I create some widgets that are out of the QGridLayout(its parent is the MainWidget).

Thanks for replies,