Remove the "stat" shell function (stat op format target value).

It has been unused since revision 1.14 dated 2006-05-30.
This commit is contained in:
apb 2012-08-14 10:38:40 +00:00
parent c3c4374a7d
commit beaffa0794
1 changed files with 1 additions and 26 deletions

View File

@ -1,6 +1,6 @@
#!/bin/sh
#
# $NetBSD: postinstall,v 1.141 2012/08/13 18:22:25 martin Exp $
# $NetBSD: postinstall,v 1.142 2012/08/14 10:38:40 apb Exp $
#
# Copyright (c) 2002-2008 The NetBSD Foundation, Inc.
# All rights reserved.
@ -411,31 +411,6 @@ find_file_in_dirlist()
return 1
}
# stat op format target value
# Call stat(1) on the given target according to the given format,
# if stat(1) is available (it is presumed to live in /usr/bin).
# If it is not available, this routine will always succeed, otherwise
# it returns 0 or 1, depending on whether or not the output from
# stat(1) matches the expected value.
#
stat()
{
_stop="$1"
_stfmt="$2"
_sttgt="$3"
_stval="$4"
if [ ! -x /usr/bin/stat ]; then
msg \
"(/usr/bin/stat not available; skipping ${_stop} on ${_sttgt})"
return 0
fi
_stres="$(/usr/bin/stat -q -f "${_stfmt}" "${_sttgt}")"
[ "${_stres}" = "${_stval}" ]
return $?
}
# file_exists_exact path
# Returns true if a file exists in the ${DEST_DIR} whose name
# is exactly ${path}, interpreted in a case-sensitive way