vidcontrol: skip invalid video modes returned by vt(4)
authoremaste <emaste@FreeBSD.org>
Mon, 20 Apr 2015 17:43:55 +0000 (17:43 +0000)
committeremaste <emaste@FreeBSD.org>
Mon, 20 Apr 2015 17:43:55 +0000 (17:43 +0000)
commit4f24a027f8b28c1a9960ed43d66b8929a1e4542a
treed44a6faf01fbfcc8bbf7b5d1c19b4e27befec2a3
parent8da3c52e6bf9c53a921feb38b55d5d6bb0d91106
vidcontrol: skip invalid video modes returned by vt(4)

vt(4) has a stub CONS_MODEINFO ioctl that does not provide any data
but returns success. This needs to be fixed in the kernel, but address
it in vidcontrol(1) as well in case it's run on an older kernel.

Reviewed by: bde
Sponsored by: The FreeBSD Foundation
usr.sbin/vidcontrol/vidcontrol.c