ufs_vnops.c (338902) | ufs_vnops.c (341074) |
---|---|
1/*- 2 * Copyright (c) 1982, 1986, 1989, 1993, 1995 3 * The Regents of the University of California. All rights reserved. 4 * (c) UNIX System Laboratories, Inc. 5 * All or some portions of this file are derived from material licensed 6 * to the University of California by American Telephone and Telegraph 7 * Co. or Unix System Laboratories, Inc. and are reproduced herein with 8 * the permission of UNIX System Laboratories, Inc. --- 21 unchanged lines hidden (view full) --- 30 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 31 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 32 * SUCH DAMAGE. 33 * 34 * @(#)ufs_vnops.c 8.27 (Berkeley) 5/27/95 35 */ 36 37#include <sys/cdefs.h> | 1/*- 2 * Copyright (c) 1982, 1986, 1989, 1993, 1995 3 * The Regents of the University of California. All rights reserved. 4 * (c) UNIX System Laboratories, Inc. 5 * All or some portions of this file are derived from material licensed 6 * to the University of California by American Telephone and Telegraph 7 * Co. or Unix System Laboratories, Inc. and are reproduced herein with 8 * the permission of UNIX System Laboratories, Inc. --- 21 unchanged lines hidden (view full) --- 30 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 31 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 32 * SUCH DAMAGE. 33 * 34 * @(#)ufs_vnops.c 8.27 (Berkeley) 5/27/95 35 */ 36 37#include <sys/cdefs.h> |
38__FBSDID("$FreeBSD: stable/11/sys/ufs/ufs/ufs_vnops.c 338902 2018-09-24 10:03:37Z kib $"); | 38__FBSDID("$FreeBSD: stable/11/sys/ufs/ufs/ufs_vnops.c 341074 2018-11-27 16:51:18Z markj $"); |
39 40#include "opt_quota.h" 41#include "opt_suiddir.h" 42#include "opt_ufs.h" 43#include "opt_ffs.h" 44 45#include <sys/param.h> 46#include <sys/systm.h> --- 2164 unchanged lines hidden (view full) --- 2211 error = EIO; 2212 break; 2213 } 2214 if (offset < startoffset || dp->d_ino == 0) 2215 goto nextentry; 2216 dstdp.d_fileno = dp->d_ino; 2217 dstdp.d_reclen = GENERIC_DIRSIZ(&dstdp); 2218 bcopy(dp->d_name, dstdp.d_name, dstdp.d_namlen); | 39 40#include "opt_quota.h" 41#include "opt_suiddir.h" 42#include "opt_ufs.h" 43#include "opt_ffs.h" 44 45#include <sys/param.h> 46#include <sys/systm.h> --- 2164 unchanged lines hidden (view full) --- 2211 error = EIO; 2212 break; 2213 } 2214 if (offset < startoffset || dp->d_ino == 0) 2215 goto nextentry; 2216 dstdp.d_fileno = dp->d_ino; 2217 dstdp.d_reclen = GENERIC_DIRSIZ(&dstdp); 2218 bcopy(dp->d_name, dstdp.d_name, dstdp.d_namlen); |
2219 dstdp.d_name[dstdp.d_namlen] = '\0'; | 2219 dirent_terminate(&dstdp); |
2220 if (dstdp.d_reclen > uio->uio_resid) { 2221 if (uio->uio_resid == startresid) 2222 error = EINVAL; 2223 else 2224 error = EJUSTRETURN; 2225 break; 2226 } 2227 /* Advance dp. */ --- 557 unchanged lines hidden --- | 2220 if (dstdp.d_reclen > uio->uio_resid) { 2221 if (uio->uio_resid == startresid) 2222 error = EINVAL; 2223 else 2224 error = EJUSTRETURN; 2225 break; 2226 } 2227 /* Advance dp. */ --- 557 unchanged lines hidden --- |