It is really a big problem....
I am writing my final year project using Motif and C under Solaris and
it should work at home with Linux too I hope...
But the progarm is now ok at Solaris, but core dump at my Linux 2.0.17
with gcc 2.7.
Following is my procedure...
1) I make a pointer to a structure which have some strings and some other
structure pointer inside. I fill up all the field under a procedure using
strdup.
2) I run a procedure to free all resources like memory for pointer.
3) Then I run step 1) again. Core dump....
No problem at Solaris at university. I can create and destroy 100 times
at Solaris without any problem. The core dump is not out at the 1st
strdup under the creation routine... One of my testing program dump at
the 3rd one and one dump at the 6th one.
What's wrong.... It true to me and I am not telling lies. Pls help.
--
---
Bestregards
Louis Chan
/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
/_/ Louis Chan, Kwong Kit /_/_
/_/_/ Computer Studies, Year 4 /_/_/
/_/ City Univerity of Hong Kong. /_/
/_/ /_/
/_/ http://www.cs.cityu.edu.hk/~ckkchan /_/
/_/ pager : +(852)7111 1076 a/c 4624 /_/
/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
Printed on Recycled Paper.