mirror of
https://github.com/churchers/vm-bhyve.git
synced 2025-12-11 09:20:17 +01:00
Fix maximum name length in core::rename
This commit is contained in:
@@ -25,7 +25,7 @@
|
||||
# POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
VERSION=1.5-devel
|
||||
VERSION_INT=105008
|
||||
VERSION_INT=105009
|
||||
VERSION_BSD=$(uname -K)
|
||||
PATH=${PATH}:/bin:/usr/bin:/usr/local/bin:/sbin:/usr/sbin:/usr/local/sbin
|
||||
|
||||
|
||||
@@ -817,7 +817,7 @@ core::rename(){
|
||||
local _new="$2"
|
||||
|
||||
[ -z "${_old}" -o -z "${_new}" ] && util::usage
|
||||
util::check_name "${_new}" || util::err "invalid virtual machine name - '${_name}'"
|
||||
util::check_name "${_new}" 46 || util::err "invalid virtual machine name - '${_name}'"
|
||||
|
||||
datastore::get_guest "${_new}" && util::err "directory ${VM_DS_PATH}/${_new} already exists"
|
||||
datastore::get_guest "${_old}" || util::err "${_old} doesn't appear to be a valid virtual machine"
|
||||
|
||||
Reference in New Issue
Block a user