syslog crashes with heap corruption

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

The syslog function in my program (which runs in kernal mode) is
crashing.  From the stack trace I found that, the malloc function is
causing heap correption in between the syslog calls.  Iam using
redhat6.1 with glibc2.1.x.i386.rpm.

To narrow down the problem, I have added some more syslog messages, that
time the application is not crashing.  So it is very clear that syslog
function in turn uses malloc (actually syslog calls vsyslog and vsyslog
calls malloc) and because of some reason it is corrupting the heap and
it crashes. Iam not using any signals in my program.  But Iam using
callback functions.

This is my stack trace,

(gdb) bt
#0  0x258d3ea8 in malloc () from /lib/libc.so.6
#1  0x258d35ce in malloc () from /lib/libc.so.6
#2  0x258ce15c in open_memstream () from /lib/libc.so.6
#3  0x25929360 in vsyslog () from /lib/libc.so.6
#4  0x259292bf in syslog () from /lib/libc.so.6
:
:
:

Will MALLOC_CHECK_ environment variable will help me out in some way?
Iam getting really bugged of with this bug.

It will be a very big relief, if somebody could help me out on this.

Thanks in advance
Gopinathan N

--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux