core dump at _malloc_unlocked

M

Martin

Hi,
I am developing a "huge" and portable software which works fine
on windows in Release/Debug Mode and on Unix in Debug Mode but crashes
when it "new" an object(GL_V5_CCM_RQRealTime_Rpy* msgBody = new
GL_V5_CCM_RQRealTime_Rpy;) in Release Mode. I got a core and i used
dbx to back trace to "_malloc_unlocked". I have used purify(Windows)
to check if there is anything wrong and i also use "_heapchk()" in
windows and everything goes fine. It seems to be platform specific and
Solaris seems to be 'stricter' and so it crashes. I have no clue and i
am checking the object time and time... but found nothing wrong. Now i
recompile the software again and hope it was cause by bad
'Compilation'.
Any comments are appreciated!!!!!

MC
 
J

Joona I Palaste

Martin said:
Hi,
I am developing a "huge" and portable software which works fine
on windows in Release/Debug Mode and on Unix in Debug Mode but crashes
when it "new" an object(GL_V5_CCM_RQRealTime_Rpy* msgBody = new
GL_V5_CCM_RQRealTime_Rpy;) in Release Mode. I got a core and i used
dbx to back trace to "_malloc_unlocked". I have used purify(Windows)
to check if there is anything wrong and i also use "_heapchk()" in
windows and everything goes fine. It seems to be platform specific and
Solaris seems to be 'stricter' and so it crashes. I have no clue and i
am checking the object time and time... but found nothing wrong. Now i
recompile the software again and hope it was cause by bad
'Compilation'.
Any comments are appreciated!!!!!

OK. Not only is this platform specific (C doesn't specify anything
about how malloc() is implemented), it's not even C in the first place.
You mention "newing" an object (GL_V5_CCM_RQRealTime_Rpy* msgBody =
new GL_V5_CCM_RQRealTime_Rpy;). This is a syntax error in C, because the
new operator is C++ only.
So this post is hopelessly off-topic on comp.lang.c. You'd even have
more luck on comp.lang.c++, although they don't handle platform
specific stuff either. (Why not try comp.lang.fortran while you're at
it? =) )
If you want to ask about Windows, there's always
comp.os.ms-windows.programmer.misc and
comp.os.ms-windows.programmer.win32. Solaris stuff could be on-topic on
comp.unix.programmer.

--
/-- Joona Palaste ([email protected]) ---------------------------\
| Kingpriest of "The Flying Lemon Tree" G++ FR FW+ M- #108 D+ ADA N+++|
| http://www.helsinki.fi/~palaste W++ B OP+ |
\----------------------------------------- Finland rules! ------------/
"Life without ostriches is like coffee with milk."
- Mika P. Nieminen
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,768
Messages
2,569,574
Members
45,051
Latest member
CarleyMcCr

Latest Threads

Top