[Qt-interest] Crashing without debug mode- No crashing with gdb debugger
Jaco Naude
naude.jaco at gmail.com
Tue Feb 8 09:41:23 CET 2011
How do you know where it is crashing if it works when you debug? From what
you are saying it sounds like your instance (this) is invalid. Check the
code where you are creating your CScrollArea instance that you have a valid
instance. Maybe Q_ASSERT it or something.
Cheers,
Jaco
On Mon, Feb 7, 2011 at 9:25 PM, Sujan Dasmahapatra <sdh at lmwindpower.com>wrote:
>
>
> Dear All
>
> I am facing some problem in implementing a QScrollArea. I subclassed it
> and created a buttin on this as below.
>
>
>
> CScrollArea::CScrollArea() {
>
> printbutton = new QPushButton("Save As Image",this);
>
> printbutton->setGeometry(actual_page_width + coordx-100,coordy,100,25);
>
> connect(printbutton,SIGNAL(clicked()),this,SLOT(gotoprinter()));
>
> }
>
>
>
> the problem is that when I am trying show this scrollarea through menu
> click its crashing. and crashing at the first line
>
> printbutton = new QPushButton("Save As Image",this);
>
>
>
> but when I am debugging this through gdb debugger then its running fine and
> at the end i can see the scroll are with button.
>
>
>
> Why is happening like this. Any idea from anyone would be highly
> appreciate.
>
> Also when I try to set a window title like
>
> setWindowTitle("My Page");
>
> its again crashing.
>
> Thanks in advance for any help. sujan
>
>
>
>
>
> Kind Regards,
>
>
>
>
>
> *Sujan Dasmahapatra
> *Project Leader, Aero Group
> Aero Group
>
> Tel +91 80 66470248
> Mob
>
> sdh at lmwindpower.com <%25EMAIL%25>
>
>
>
> *LM Wind Power Blades*
>
> lmwindpower.com
>
>
>
> *Together we capture the wind to power a cleaner world*
> ------------------------------
>
>
>
> This e-mail and any attachments are confidential. If you are not the named
> or intended recipient, please notify the sender immediately and do not
> disclose the contents to any other person, use it for any purpose, or store
> or copy the information in any medium. Any unauthorized disclosure, use or
> storage is prohibited and might be unlawful.
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at qt.nokia.com
> http://lists.qt.nokia.com/mailman/listinfo/qt-interest
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20110208/922f817d/attachment.html
More information about the Qt-interest-old
mailing list