|
From: prasad <pg...@ma...> - 2005-01-05 05:41:41
|
Hi,
I am trying to debug my server for memory leaks which is
highly multithreaded with valgrind.
Problem is that valgrind doesn't check for leaks in the threads spawned
by
main server thread.
Server is listening for the requests and constantly running but with
valgrind it
returns immediately after finishing initialization activities.
Specifically after running my server with valgrind it doesn't run as a
server process.
Does somebody knows how to debug a multithreade server with valgrind.
Prasad.
*********************************************************
Disclaimer:
This message (including any attachments) contains
confidential information intended for a specific
individual and purpose, and is protected by law.
If you are not the intended recipient, you should
delete this message and are hereby notified that
any disclosure, copying, or distribution of this
message, or the taking of any action based on it,
is strictly prohibited.
*********************************************************
Visit us at http://www.mahindrabt.com
|
|
From: Dennis L. <pla...@tz...> - 2005-01-05 10:48:59
|
Am Mittwoch, den 05.01.2005, 11:10 +0530 schrieb prasad: > Hi, > > I am trying to debug my server for memory leaks which is > highly multithreaded with valgrind. > > Problem is that valgrind doesn't check for leaks in the threads spawned > by > main server thread. Do you really mean threads, or child processes (via fork, exec) ? valgrind per default does check posix-threads, but does not check child processes. This has to be done with the --trace-children=yes option. >From my experience I can say that most servers "fork themselves to the background" i.e. do a fork/exec and return from the original process started. So either try the --trace-children or tell the server not to fork... greeets Dennis -- Dennis Lubert <pla...@tz...> |