X-Git-Url: https://git.subgeniuskitty.com/unix-history/.git/blobdiff_plain/f5d8beae31a161eca2f6e901612a967e1491b8e0..bc258617f323d737755d6043c64ffea2c59b69d4:/usr/src/usr.bin/more/help.c diff --git a/usr/src/usr.bin/more/help.c b/usr/src/usr.bin/more/help.c index 9a4766f5cf..b0f2d91b68 100644 --- a/usr/src/usr.bin/more/help.c +++ b/usr/src/usr.bin/more/help.c @@ -3,15 +3,13 @@ * Copyright (c) 1988 Regents of the University of California. * All rights reserved. * - * This code is derived from software contributed to Berkeley by - * Mark Nudleman. - * * Redistribution and use in source and binary forms are permitted * provided that the above copyright notice and this paragraph are * duplicated in all such forms and that any documentation, * advertising materials, and other materials related to such * distribution and use acknowledge that the software was developed - * by the University of California, Berkeley. The name of the + * by Mark Nudleman and the University of California, Berkeley. The + * name of Mark Nudleman or the * University may not be used to endorse or promote products derived * from this software without specific prior written permission. * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR @@ -20,28 +18,17 @@ */ #ifndef lint -static char sccsid[] = "@(#)help.c 5.2 (Berkeley) %G%"; +static char sccsid[] = "@(#)help.c 5.5 (Berkeley) %G%"; #endif /* not lint */ -#include "less.h" +#include +#include -/* - * Display some help. - * Just invoke another "less" to display the help file. - * - * {{ This makes this function very simple, and makes changing the - * help file very easy, but it may present difficulties on - * (non-Unix) systems which do not supply the "system()" function. }} - */ - - public void +#define HELPFILE "/usr/lib/more.help" help() { - char cmd[MAXPATHLEN+100]; + char cmd[MAXPATHLEN + 20]; - (void)sprintf(cmd, - "-less -m '-PmHELP -- ?eEND -- Press g to see it again:Press RETURN for more., or q when done ' %s", - HELPFILE); + (void)sprintf(cmd, "-more %s", HELPFILE); lsystem(cmd); - error("End of help"); }