From owner-svn-src-head@freebsd.org Sun Jan 8 06:22:36 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B1700CA5B92; Sun, 8 Jan 2017 06:22:36 +0000 (UTC) (envelope-from cem@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7FE901E87; Sun, 8 Jan 2017 06:22:36 +0000 (UTC) (envelope-from cem@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v086MZcw022056; Sun, 8 Jan 2017 06:22:35 GMT (envelope-from cem@FreeBSD.org) Received: (from cem@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v086MZ7o022055; Sun, 8 Jan 2017 06:22:35 GMT (envelope-from cem@FreeBSD.org) Message-Id: <201701080622.v086MZ7o022055@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cem set sender to cem@FreeBSD.org using -f From: "Conrad E. Meyer" Date: Sun, 8 Jan 2017 06:22:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r311666 - head/sys/fs/cd9660 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 08 Jan 2017 06:22:36 -0000 Author: cem Date: Sun Jan 8 06:22:35 2017 New Revision: 311666 URL: https://svnweb.freebsd.org/changeset/base/311666 Log: Do not truncate inode calculation from ISO9660 block offset PR: 190655 Reported by: Thomas Schmitt Obtained from: NetBSD sys/fs/cd9660/cd9660_node.c,r1.31 Modified: head/sys/fs/cd9660/cd9660_node.c Modified: head/sys/fs/cd9660/cd9660_node.c ============================================================================== --- head/sys/fs/cd9660/cd9660_node.c Sun Jan 8 06:21:49 2017 (r311665) +++ head/sys/fs/cd9660/cd9660_node.c Sun Jan 8 06:22:35 2017 (r311666) @@ -316,7 +316,14 @@ isodirino(isodir, imp) { cd_ino_t ino; - ino = (isonum_733(isodir->extent) + isonum_711(isodir->ext_attr_length)) - << imp->im_bshift; - return (ino); + /* + * Note there is an inverse calculation in + * cd9660_vfsops.c:cd9660_vget_internal(): + * ip->iso_start = ino >> imp->im_bshift; + * and also a calculation of the isodir pointer + * from an inode in cd9660_vnops.c:cd9660_readlink() + */ + ino = ((cd_ino_t)isonum_733(isodir->extent) + + isonum_711(isodir->ext_attr_length)) << imp->im_bshift; + return ino; }