Move pledge after opendev and DIOCGPDINFO. Fixes e.g. fdisk /dev/tty.
authortb <tb@openbsd.org>
Sat, 25 Jun 2016 17:03:22 +0000 (17:03 +0000)
committertb <tb@openbsd.org>
Sat, 25 Jun 2016 17:03:22 +0000 (17:03 +0000)
commit1dbdb6ae7a5317b0d6fa82896edc177421cc3464
tree3ac04d5320de79da7c8205ebaa55fbd4a952b9bd
parent29d580d577487f2e1ba941eb27855117d7e3eae6
Move pledge after opendev and DIOCGPDINFO. Fixes e.g. fdisk /dev/tty.
This diff by deraadt was overlooked far too many times, mostly by me.
It's the original fix of the pledge disklabel breakage found by espie.

diff by deraadt; ok semarie, tb.
sbin/fdisk/fdisk.c