From owner-cvs-src@FreeBSD.ORG Fri Aug 8 18:55:39 2003 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1E55337B405; Fri, 8 Aug 2003 18:55:39 -0700 (PDT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id A996743F75; Fri, 8 Aug 2003 18:55:38 -0700 (PDT) (envelope-from marcel@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.12.6/8.12.6) with ESMTP id h791tc0U060073; Fri, 8 Aug 2003 18:55:38 -0700 (PDT) (envelope-from marcel@repoman.freebsd.org) Received: (from marcel@localhost) by repoman.freebsd.org (8.12.6/8.12.6/Submit) id h791tc7P060069; Fri, 8 Aug 2003 18:55:38 -0700 (PDT) Message-Id: <200308090155.h791tc7P060069@repoman.freebsd.org> From: Marcel Moolenaar Date: Fri, 8 Aug 2003 18:55:38 -0700 (PDT) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/usr.bin/elfdump elfdump.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 09 Aug 2003 01:55:39 -0000 marcel 2003/08/08 18:55:38 PDT FreeBSD src repository Modified files: usr.bin/elfdump elfdump.c Log: Fix sign-extension bug for 32 and 64-bit values. For 64-bit values this involves the sign-extension of the high and low "word". Both of which are 32-bit. The bug is especially harmful on ia64, where 0x9fffffffe0000000 is a common address (base of register stack). This was invariably displayed as 0xffffffffe0000000. The sign-extension is fixed by using {b|l}e{16|32|64}dec() where applicable. Since elfdump(1) is not a bootstrap tool, dependency on these functions is not a problem. Revision Changes Path 1.9 +27 -39 src/usr.bin/elfdump/elfdump.c