From owner-cvs-all@FreeBSD.ORG Thu Jan 12 13:18:49 2006 Return-Path: X-Original-To: cvs-all@FreeBSD.org Delivered-To: cvs-all@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D9A5216A41F; Thu, 12 Jan 2006 13:18:49 +0000 (GMT) (envelope-from marius@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 918DB43D58; Thu, 12 Jan 2006 13:18:49 +0000 (GMT) (envelope-from marius@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id k0CDInmh004799; Thu, 12 Jan 2006 13:18:49 GMT (envelope-from marius@repoman.freebsd.org) Received: (from marius@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id k0CDInws004798; Thu, 12 Jan 2006 13:18:49 GMT (envelope-from marius) Message-Id: <200601121318.k0CDInws004798@repoman.freebsd.org> From: Marius Strobl Date: Thu, 12 Jan 2006 13:18:49 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Cc: Subject: cvs commit: src/sys/boot/common module.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 12 Jan 2006 13:18:50 -0000 marius 2006-01-12 13:18:49 UTC FreeBSD src repository Modified files: sys/boot/common module.c Log: In moduledir_readhints() cast the value returned by sizeof() to ssize_t when checking whether it's greater than a struct stat st_size in order to also catch the case when st_size is -1. Previously this check didn't trigger on sparc64 when st_size is -1 (as it's the case for a file on a bzipfs, TFTP server etc.), causing the content of the linker hints file to be copied to memory referenced by a null-pointer. PR: 91231 MFC after: 1 week Revision Changes Path 1.26 +2 -1 src/sys/boot/common/module.c