svn commit: r227660 - head/libexec/rtld-elf

Konstantin Belousov kib at FreeBSD.org
Fri Nov 18 09:55:47 UTC 2011


Author: kib
Date: Fri Nov 18 09:55:47 2011
New Revision: 227660
URL: http://svn.freebsd.org/changeset/base/227660

Log:
  Fix fd leak.
  
  Reported by:	slonoman2011 yandex ru
  MFC after:	1 week

Modified:
  head/libexec/rtld-elf/rtld.c

Modified: head/libexec/rtld-elf/rtld.c
==============================================================================
--- head/libexec/rtld-elf/rtld.c	Fri Nov 18 09:54:14 2011	(r227659)
+++ head/libexec/rtld-elf/rtld.c	Fri Nov 18 09:55:47 2011	(r227660)
@@ -1657,6 +1657,7 @@ load_object(const char *name, const Obj_
     }
     if (flags & RTLD_LO_NOLOAD) {
 	free(path);
+	close(fd);
 	return (NULL);
     }
 


More information about the svn-src-all mailing list