diff options
author | bapt <bapt@FreeBSD.org> | 2015-05-03 19:30:11 +0000 |
---|---|---|
committer | bapt <bapt@FreeBSD.org> | 2015-05-03 19:30:11 +0000 |
commit | b5633ba2a5f5c5e3fddb07ef1f3c114268f7ea42 (patch) | |
tree | 43730ad7995cdbd70d25f4f9739ec3b2abd10b91 /usr.sbin/vidcontrol/vidcontrol.c | |
parent | 249cdb0bbbb0d59f85a71e76323eeed99d6d3134 (diff) | |
parent | 4cd4238e928bc196c424f1549c026c4f4407fba6 (diff) | |
download | FreeBSD-src-b5633ba2a5f5c5e3fddb07ef1f3c114268f7ea42.zip FreeBSD-src-b5633ba2a5f5c5e3fddb07ef1f3c114268f7ea42.tar.gz |
Merge from head
Diffstat (limited to 'usr.sbin/vidcontrol/vidcontrol.c')
-rw-r--r-- | usr.sbin/vidcontrol/vidcontrol.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/usr.sbin/vidcontrol/vidcontrol.c b/usr.sbin/vidcontrol/vidcontrol.c index 3001f69..cbf8f47 100644 --- a/usr.sbin/vidcontrol/vidcontrol.c +++ b/usr.sbin/vidcontrol/vidcontrol.c @@ -1085,12 +1085,16 @@ show_mode_info(void) printf("---------------------------------------" "---------------------------------------\n"); + memset(&_info, 0, sizeof(_info)); for (mode = 0; mode <= M_VESA_MODE_MAX; ++mode) { _info.vi_mode = mode; if (ioctl(0, CONS_MODEINFO, &_info)) continue; if (_info.vi_mode != mode) continue; + if (_info.vi_width == 0 && _info.vi_height == 0 && + _info.vi_cwidth == 0 && _info.vi_cheight == 0) + continue; printf("%3d (0x%03x)", mode, mode); printf(" 0x%08x", _info.vi_flags); @@ -1343,7 +1347,7 @@ main(int argc, char **argv) if (vt4_mode) opts = "b:Cc:fg:h:Hi:M:m:pPr:S:s:T:t:x"; else - opts = "b:Cc:df:g:h:Hi:l:LM:m:pPr:S:s:T:t:x"; + opts = "b:Cc:dfg:h:Hi:l:LM:m:pPr:S:s:T:t:x"; while ((opt = getopt(argc, argv, opts)) != -1) switch(opt) { |