From owner-svn-src-all@FreeBSD.ORG Sat Jan 8 10:56:58 2011 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 78AE7106566B; Sat, 8 Jan 2011 10:56:58 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 67ED08FC14; Sat, 8 Jan 2011 10:56:58 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p08AuwTR088928; Sat, 8 Jan 2011 10:56:58 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p08Auwqu088926; Sat, 8 Jan 2011 10:56:58 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201101081056.p08Auwqu088926@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 8 Jan 2011 10:56:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217143 - head/lib/libc/net X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jan 2011 10:56:58 -0000 Author: kib Date: Sat Jan 8 10:56:58 2011 New Revision: 217143 URL: http://svn.freebsd.org/changeset/base/217143 Log: Fix struct FILE * leak on error (in disabled by default hesiod support code). Submitted by: henning petersen PR: 153756 MFC after: 1 week Modified: head/lib/libc/net/hesiod.c Modified: head/lib/libc/net/hesiod.c ============================================================================== --- head/lib/libc/net/hesiod.c Sat Jan 8 08:58:46 2011 (r217142) +++ head/lib/libc/net/hesiod.c Sat Jan 8 10:56:58 2011 (r217143) @@ -324,6 +324,7 @@ read_config_file(ctx, filename) ? &ctx->lhs : &ctx->rhs; *which = strdup(data); if (!*which) { + fclose(fp); errno = ENOMEM; return -1; }