1210967Spjd#!/bin/sh 2210967Spjd# $FreeBSD: releng/10.2/tools/regression/pjdfstest/tests/mknod/01.t 211474 2010-08-18 22:06:43Z pjd $ 3210967Spjd 4210967Spjddesc="mknod returns ENOTDIR if a component of the path prefix is not a directory" 5210967Spjd 6210967Spjddir=`dirname $0` 7210967Spjd. ${dir}/../misc.sh 8210967Spjd 9211474Spjdecho "1..27" 10210967Spjd 11210967Spjdn0=`namegen` 12210967Spjdn1=`namegen` 13210967Spjd 14210967Spjdexpect 0 mkdir ${n0} 0755 15211474Spjdfor type in regular fifo block char socket; do 16211474Spjd create_file ${type} ${n0}/${n1} 17211474Spjd expect ENOTDIR mknod ${n0}/${n1}/test b 0644 1 2 18211474Spjd expect ENOTDIR mknod ${n0}/${n1}/test c 0644 1 2 19211474Spjd expect ENOTDIR mknod ${n0}/${n1}/test f 0644 0 0 20211474Spjd expect 0 unlink ${n0}/${n1} 21211474Spjddone 22210967Spjdexpect 0 rmdir ${n0} 23