From: Julian Seward Date: Mon, 11 Dec 2006 01:11:02 +0000 (+0000) Subject: Tidy fd-leak stuff a bit. X-Git-Tag: svn/VALGRIND_3_3_0~495 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=52cf6ff843c500013e9c97bcd81eccc26059a782;p=thirdparty%2Fvalgrind.git Tidy fd-leak stuff a bit. git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6391 --- diff --git a/coregrind/m_syswrap/syswrap-generic.c b/coregrind/m_syswrap/syswrap-generic.c index deb7c7786e..30534d36b0 100644 --- a/coregrind/m_syswrap/syswrap-generic.c +++ b/coregrind/m_syswrap/syswrap-generic.c @@ -452,7 +452,7 @@ typedef struct OpenFd } OpenFd; /* List of allocated file descriptors. */ -static OpenFd *allocated_fds; +static OpenFd *allocated_fds = NULL; /* Count of open file descriptors. */ static Int fd_count = 0; @@ -627,7 +627,7 @@ getsockdetails(Int fd) /* Dump out a summary, and a more detailed list, of open file descriptors. */ -void VG_(show_open_fds) () +void VG_(show_open_fds) (void) { OpenFd *i = allocated_fds; @@ -691,7 +691,7 @@ void do_hacky_preopened(void) /* Initialize the list of open file descriptors with the file descriptors we inherited from out parent process. */ -void VG_(init_preopened_fds)() +void VG_(init_preopened_fds)(void) { Int ret; struct vki_dirent d;