bsdinstall/zfsboot: Do not mirror swap when swapsize is 0

PR:		209415
Submitted by:	Ganael LAPLANCHE <ganael.laplanche@corp.ovh.com>
MFC after:	2 weeks
This commit is contained in:
Allan Jude 2016-05-10 14:38:43 +00:00
parent ebf75b599a
commit 06445fc0fa

View File

@ -1233,7 +1233,7 @@ zfs_create_boot()
#
# Create the gmirror(8) GEOMS for swap
#
if [ "$ZFSBOOT_SWAP_MIRROR" ]; then
if [ ${swapsize:-0} -gt 0 -a "$ZFSBOOT_SWAP_MIRROR" ]; then
for disk in $disks; do
swap_devs="$swap_devs $disk$swappart"
done