invalid pointer error

Mohamed Shafi shafitvm@gmail.com
Fri Aug 3 06:15:00 GMT 2007


On 8/3/07, Anitha Boyapati <anithab@sankhya.com> wrote:
>
>
> On Fri, 3 Aug 2007, Mohamed Shafi wrote:
>
> >
> > *** glibc detected *** ./readpro.exe: free(): invalid pointer: 0x00c5ac80 ***
>
>  This is clearly a memory associated error. You are possibly trying to
>  free some memory which is not allocated in one of the destructors as
>  you reach the end of program.
>
>  Check if you are using delete[] where delete suffices.

I forgot to mention. I am not at all allocating any memory in my
program and hence delete is not used. Thats why i am very confused.

>
>
> > ======= Backtrace: =========
> > /lib/libc.so.6[0xb8ef18]
> > /lib/libc.so.6(__libc_free+0x79)[0xb9241d]
> > /lib/libc.so.6(exit+0x88)[0xb559a8]
> > /lib/libc.so.6(__libc_start_main+0xe4)[0xb407ec]
> > ./readpro.exe[0x8048471]
> > ======= Memory map: ========
> > 00225000-00230000 r-xp 00000000 08:02 1475588
> > /lib/libgcc_s-4.1.0-20060304.so.1
> > 00230000-00231000 rw-p 0000a000 08:02 1475588
> > /lib/libgcc_s-4.1.0-20060304.so.1
> > 0029e000-002b7000 r-xp 00000000 08:02 1475582    /lib/ld-2.4.so
> > 002b7000-002b8000 r--p 00018000 08:02 1475582    /lib/ld-2.4.so
> > 002b8000-002b9000 rw-p 00019000 08:02 1475582    /lib/ld-2.4.so
> > 00447000-00448000 r-xp 00447000 00:00 0          [vdso]
> > 00b2b000-00c57000 r-xp 00000000 08:02 1475583    /lib/libc-2.4.so
> > 00c57000-00c5a000 r--p 0012b000 08:02 1475583    /lib/libc-2.4.so
> > 00c5a000-00c5b000 rw-p 0012e000 08:02 1475583    /lib/libc-2.4.so
> > 00c5b000-00c5e000 rw-p 00c5b000 00:00 0
> > 08048000-08049000 r-xp 00000000 08:07 7688505    /home/tom/readpro.exe
> > 08049000-0804a000 rw-p 00000000 08:07 7688505    /home/tom/readpro.exe
> > 0921a000-0923b000 rw-p 0921a000 00:00 0          [heap]
> > b7f13000-b7f14000 rw-p b7f13000 00:00 0
> > b7f2f000-b7f31000 rw-p b7f2f000 00:00 0
> > bfe1b000-bfe31000 rw-p bfe1b000 00:00 0          [stack]
> > Aborted
> >
> >
> > Regards,
> > Shafi
> >
>
> --
> Regards,
> Anitha B
> @S A N K H Y A
>
>



More information about the Gcc-help mailing list