=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/less/command.c,v retrieving revision 1.23 retrieving revision 1.24 diff -c -r1.23 -r1.24 *** src/usr.bin/less/command.c 2015/11/09 14:25:32 1.23 --- src/usr.bin/less/command.c 2015/11/09 16:39:13 1.24 *************** *** 227,237 **** /* POSIX behavior - probably not generally useful */ if (less_is_more && (strcmp(cbuf, "#") == 0)) { if (ntags()) { ! error("No previous file", NULL_PARG); break; } if (edit_prev(1)) { ! error("No previous file", NULL_PARG); } else { jump_back(1); } --- 227,237 ---- /* POSIX behavior - probably not generally useful */ if (less_is_more && (strcmp(cbuf, "#") == 0)) { if (ntags()) { ! error("No previous file", NULL); break; } if (edit_prev(1)) { ! error("No previous file", NULL); } else { jump_back(1); } *************** *** 245,251 **** if (secure) break; (void) pipe_mark(pipec, cbuf); ! error("|done", NULL_PARG); break; } } --- 245,251 ---- if (secure) break; (void) pipe_mark(pipec, cbuf); ! error("|done", NULL); break; } } *************** *** 857,863 **** * Print an error message if we haven't already. */ if (n > 0) ! error("Pattern not found", NULL_PARG); if (changed_file) { /* --- 857,863 ---- * Print an error message if we haven't already. */ if (n > 0) ! error("Pattern not found", NULL); if (changed_file) { /* *************** *** 1375,1381 **** error(less_is_more ? "Invalid option -p h" : "Invalid option ++h", ! NULL_PARG); break; } cmd_exec(); --- 1375,1381 ---- error(less_is_more ? "Invalid option -p h" : "Invalid option ++h", ! NULL); break; } cmd_exec(); *************** *** 1389,1395 **** * Edit a new file. Get the filename. */ if (secure) { ! error("Command not available", NULL_PARG); break; } start_mca(A_EXAMINE, "Examine: ", ml_examine, 0); --- 1389,1395 ---- * Edit a new file. Get the filename. */ if (secure) { ! error("Command not available", NULL); break; } start_mca(A_EXAMINE, "Examine: ", ml_examine, 0); *************** *** 1401,1418 **** * Invoke an editor on the input file. */ if (secure) { ! error("Command not available", NULL_PARG); break; } if (ch_getflags() & CH_HELPFILE) break; if (strcmp(get_filename(curr_ifile), "-") == 0) { ! error("Cannot edit standard input", NULL_PARG); break; } if (curr_altfilename != NULL) { error("WARNING: This file was viewed via " ! "LESSOPEN", NULL_PARG); } /* * Expand the editor prototype string --- 1401,1418 ---- * Invoke an editor on the input file. */ if (secure) { ! error("Command not available", NULL); break; } if (ch_getflags() & CH_HELPFILE) break; if (strcmp(get_filename(curr_ifile), "-") == 0) { ! error("Cannot edit standard input", NULL); break; } if (curr_altfilename != NULL) { error("WARNING: This file was viewed via " ! "LESSOPEN", NULL); } /* * Expand the editor prototype string *************** *** 1430,1436 **** * Examine next file. */ if (ntags()) { ! error("No next file", NULL_PARG); break; } if (number <= 0) --- 1430,1436 ---- * Examine next file. */ if (ntags()) { ! error("No next file", NULL); break; } if (number <= 0) *************** *** 1449,1455 **** * Examine previous file. */ if (ntags()) { ! error("No previous file", NULL_PARG); break; } if (number <= 0) --- 1449,1455 ---- * Examine previous file. */ if (ntags()) { ! error("No previous file", NULL); break; } if (number <= 0) *************** *** 1465,1471 **** number = 1; tagfile = nexttag((int)number); if (tagfile == NULL) { ! error("No next tag", NULL_PARG); break; } if (edit(tagfile) == 0) { --- 1465,1471 ---- number = 1; tagfile = nexttag((int)number); if (tagfile == NULL) { ! error("No next tag", NULL); break; } if (edit(tagfile) == 0) { *************** *** 1480,1486 **** number = 1; tagfile = prevtag((int)number); if (tagfile == NULL) { ! error("No previous tag", NULL_PARG); break; } if (edit(tagfile) == 0) { --- 1480,1486 ---- number = 1; tagfile = prevtag((int)number); if (tagfile == NULL) { ! error("No previous tag", NULL); break; } if (edit(tagfile) == 0) { *************** *** 1497,1503 **** if (number <= 0) number = 1; if (edit_index((int)number)) ! error("No such file", NULL_PARG); break; case A_REMOVE_FILE: --- 1497,1503 ---- if (number <= 0) number = 1; if (edit_index((int)number)) ! error("No such file", NULL); break; case A_REMOVE_FILE: *************** *** 1570,1576 **** case A_PIPE: if (secure) { ! error("Command not available", NULL_PARG); break; } start_mca(A_PIPE, "|mark: ", (void*)NULL, 0); --- 1570,1576 ---- case A_PIPE: if (secure) { ! error("Command not available", NULL); break; } start_mca(A_PIPE, "|mark: ", (void*)NULL, 0);