Fix misuse of the basename() and dirname() functions.
authored <ed@FreeBSD.org>
Wed, 21 Sep 2016 13:02:43 +0000 (13:02 +0000)
committered <ed@FreeBSD.org>
Wed, 21 Sep 2016 13:02:43 +0000 (13:02 +0000)
commit8ab365d2118d20faf857343556e00e688c4ad19d
tree5715dfe6e3a8bf0052869d1f1bc766c923799663
parenta26096b6928229cdee0f385e5690cdb2b8c968dc
Fix misuse of the basename() and dirname() functions.

These functions are allowed to overwrite their input. Pull a copy of the
input parameter and call dirname() and basename() on that instead. Do
ensure that we reload the pathname value between calls.
usr.sbin/bhyve/pci_virtio_console.c