=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/less/command.c,v retrieving revision 1.11 retrieving revision 1.12 diff -c -r1.11 -r1.12 *** src/usr.bin/less/command.c 2011/10/08 19:55:39 1.11 --- src/usr.bin/less/command.c 2014/04/14 20:10:33 1.12 *************** *** 1461,1466 **** --- 1461,1473 ---- */ if (ch_getflags() & CH_HELPFILE) break; + if (ungot != NULL || unget_end) { + error(less_is_more + ? "Invalid option -p h" + : "Invalid option ++h", + NULL_PARG); + break; + } cmd_exec(); save_hshift = hshift; hshift = 0;