xref: /freebsd/contrib/pjdfstest/tests/rename/17.t (revision 6829dae12bb055451fa467da4589c43bd03b1e64)
1#!/bin/sh
2# vim: filetype=sh noexpandtab ts=8 sw=8
3# $FreeBSD: head/tools/regression/pjdfstest/tests/rename/17.t 211352 2010-08-15 21:24:17Z pjd $
4
5desc="rename returns EFAULT if one of the pathnames specified is outside the process's allocated address space"
6
7dir=`dirname $0`
8. ${dir}/../misc.sh
9
10echo "1..8"
11
12n0=`namegen`
13
14expect 0 create ${n0} 0644
15expect EFAULT rename ${n0} NULL
16expect EFAULT rename ${n0} DEADCODE
17expect 0 unlink ${n0}
18expect EFAULT rename NULL ${n0}
19expect EFAULT rename DEADCODE ${n0}
20expect EFAULT rename NULL DEADCODE
21expect EFAULT rename DEADCODE NULL
22