PDA

View Full Version : Error with Debug Binaries



ashishrai
25th June 2008, 17:53
My project application runs smoothly when built in release mode.
However, when it is run after building in debug mode, I get a segmentation fault in a line which is very generic and I have been using it as a template.

QApplication app( argc, argv );

The full file is :


#include <QApplication>
#include "mainwindowimpl.h"





int main(int argc, char ** argv)
{
QApplication app( argc, argv );

MainWindowImpl win;
win.show();
app.connect( &app, SIGNAL( lastWindowClosed() ), &app, SLOT( quit() ) );


return app.exec();
}


Back trace is :

Starting program: E:\QMTSim\QMTSim1.0\bin/test5.exe


Program received signal SIGSEGV, Segmentation fault.
0x051bc66d in ?? ()
(gdb) bt
#0 0x051bc66d in ?? ()
#1 0x7c91cbab in _libkernel32_a_iname ()
#2 0x7c916178 in _libkernel32_a_iname ()
#3 0x7c9162da in _libkernel32_a_iname ()
#4 0x7c801bb9 in _libkernel32_a_iname ()
#5 0x7e42dbfb in _libkernel32_a_iname ()
#6 0x7c90eae3 in _libkernel32_a_iname ()
#7 0x7e41fecc in _libkernel32_a_iname ()
#8 0x7e41ff66 in _libkernel32_a_iname ()
#9 0x1017700a in qt_create_internal_window(QEventDispatcherWin32 const*) (
eventDispatcher=0x394b8) at kernel/qeventdispatcher_win.cpp:535
#10 0x10177632 in QPrinter::~QPrinter() ()
at kernel/qeventdispatcher_win.cpp:635
#11 0x00d91c25 in ?? ()
#12 0x00d91d4d in ?? ()
#13 0x1014694c in QCoreApplication::init() (this=0x23fde0)
at kernel/qcoreapplication.cpp:461
#14 0x101464e7 in QCoreApplication::QCoreApplication(QCoreApplicatio nPrivate&)
(this=0x23fde0, p=@0x34fd0) at kernel/qcoreapplication.cpp:392
#15 0x00d1ba4b in ?? ()
#16 0x00409ea1 in qMain(int, char**) (argc=1, argv=0x34f98) at src/main.cpp:10
#17 0x0041c2b4 in WinMain (instance=0x400000, prevInstance=0x0, cmdShow=10)
at qtmain_win.cpp:140
---Type <return> to continue, or q <return> to quit---
#18 0x0041bcea in main ()
(gdb) bt > log.txt
A parse error in expression, near ` log.txt'.
(gdb) q
The program is running. Exit anyway? (y or n) y

E:\QMTSim\QMTSim1.0\bin>

Full project can be got at code.google.com/p/qmtsim

I have not been able to figure out what to do as this goes beyond my realm.

Please help me in debugging this, me and my project is waiting to go ahead .

Thanks for your time and co-operation.

jacek
26th June 2008, 00:51
Maybe the debug versions of Qt libraries got damaged somehow?