1994-05-27 12:33:43 +00:00
|
|
|
/*-
|
2017-11-20 19:49:47 +00:00
|
|
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
|
|
*
|
1994-05-27 12:33:43 +00:00
|
|
|
* Copyright (c) 1992, 1993
|
|
|
|
* The Regents of the University of California. All rights reserved.
|
|
|
|
*
|
|
|
|
* Redistribution and use in source and binary forms, with or without
|
|
|
|
* modification, are permitted provided that the following conditions
|
|
|
|
* are met:
|
|
|
|
* 1. Redistributions of source code must retain the above copyright
|
|
|
|
* notice, this list of conditions and the following disclaimer.
|
|
|
|
* 2. Redistributions in binary form must reproduce the above copyright
|
|
|
|
* notice, this list of conditions and the following disclaimer in the
|
|
|
|
* documentation and/or other materials provided with the distribution.
|
2017-02-28 23:42:47 +00:00
|
|
|
* 3. Neither the name of the University nor the names of its contributors
|
1994-05-27 12:33:43 +00:00
|
|
|
* may be used to endorse or promote products derived from this software
|
|
|
|
* without specific prior written permission.
|
|
|
|
*
|
|
|
|
* THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
|
|
|
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
|
|
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
|
|
* ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
|
|
|
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
|
|
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
|
|
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
|
|
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
|
|
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
|
|
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
|
|
* SUCH DAMAGE.
|
|
|
|
*
|
2001-12-18 20:52:09 +00:00
|
|
|
* @(#)extern.h 8.2 (Berkeley) 4/20/95
|
2001-03-25 04:57:05 +00:00
|
|
|
*
|
|
|
|
* $FreeBSD$
|
1994-05-27 12:33:43 +00:00
|
|
|
*/
|
|
|
|
|
2002-03-22 01:33:25 +00:00
|
|
|
struct name *cat(struct name *, struct name *);
|
2016-07-15 15:37:54 +00:00
|
|
|
struct name *delname(struct name *, char *);
|
2002-03-22 01:33:25 +00:00
|
|
|
struct name *elide(struct name *);
|
2016-07-15 15:37:54 +00:00
|
|
|
struct name *extract(char *, int);
|
2002-03-22 01:33:25 +00:00
|
|
|
struct name *gexpand(struct name *, struct grouphead *, int, int);
|
2016-07-15 15:37:54 +00:00
|
|
|
struct name *nalloc(char *, int);
|
2002-03-22 01:33:25 +00:00
|
|
|
struct name *outof(struct name *, FILE *, struct header *);
|
|
|
|
struct name *put(struct name *, struct name *);
|
|
|
|
struct name *tailof(struct name *);
|
|
|
|
struct name *usermap(struct name *);
|
|
|
|
FILE *Fdopen(int, const char *);
|
|
|
|
FILE *Fopen(const char *, const char *);
|
|
|
|
FILE *Popen(char *, const char *);
|
|
|
|
FILE *collect(struct header *, int);
|
|
|
|
char *copyin(char *, char **);
|
|
|
|
char *detract(struct name *, int);
|
|
|
|
char *expand(char *);
|
|
|
|
char *getdeadletter(void);
|
2016-07-13 16:45:26 +00:00
|
|
|
char *getname(uid_t);
|
2002-03-22 01:33:25 +00:00
|
|
|
char *hfield(const char *, struct message *);
|
|
|
|
FILE *infix(struct header *, FILE *);
|
2016-07-15 15:37:54 +00:00
|
|
|
char *ishfield(char *, char *, const char *);
|
2002-03-22 01:33:25 +00:00
|
|
|
char *name1(struct message *, int);
|
|
|
|
char *nameof(struct message *, int);
|
|
|
|
char *nextword(char *, char *);
|
2016-07-15 15:37:54 +00:00
|
|
|
char *readtty(const char *, char *);
|
2002-03-22 01:33:25 +00:00
|
|
|
char *reedit(char *);
|
|
|
|
FILE *run_editor(FILE *, off_t, int, int);
|
|
|
|
char *salloc(int);
|
|
|
|
char *savestr(char *);
|
|
|
|
FILE *setinput(struct message *);
|
|
|
|
char *skin(char *);
|
|
|
|
char *skip_comment(char *);
|
2016-07-15 15:37:54 +00:00
|
|
|
char *snarf(char *, int *);
|
2002-03-22 01:33:25 +00:00
|
|
|
char *username(void);
|
|
|
|
char *value(const char *);
|
|
|
|
char *vcopy(const char *);
|
2016-07-15 15:37:54 +00:00
|
|
|
char *yankword(char *, char *);
|
|
|
|
char *yanklogin(char *, char *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int Fclose(FILE *);
|
2016-07-15 15:37:54 +00:00
|
|
|
int More(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int Pclose(FILE *);
|
|
|
|
int Respond(int *);
|
2016-07-15 15:37:54 +00:00
|
|
|
int Type(void *);
|
|
|
|
int doRespond(int *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int dorespond(int *);
|
|
|
|
void alter(char *);
|
|
|
|
int alternates(char **);
|
|
|
|
void announce(void);
|
|
|
|
int append(struct message *, FILE *);
|
|
|
|
int argcount(char **);
|
|
|
|
void assign(const char *, const char *);
|
|
|
|
int bangexp(char *, size_t);
|
|
|
|
void brokpipe(int);
|
|
|
|
int charcount(char *, int);
|
|
|
|
int check(int, int);
|
|
|
|
void clob1(int);
|
|
|
|
int clobber(char **);
|
|
|
|
void close_all_files(void);
|
|
|
|
int cmatch(char *, char *);
|
|
|
|
void collhup(int);
|
|
|
|
void collint(int);
|
|
|
|
void collstop(int);
|
|
|
|
void commands(void);
|
2016-07-13 16:45:26 +00:00
|
|
|
int copycmd(void *v);
|
2002-03-22 01:33:25 +00:00
|
|
|
int core(void);
|
|
|
|
int count(struct name *);
|
2016-07-15 15:37:54 +00:00
|
|
|
int deletecmd(void *);
|
|
|
|
int delm(int *);
|
|
|
|
int deltype(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
void demail(void);
|
|
|
|
int diction(const void *, const void *);
|
|
|
|
int dosh(char *);
|
|
|
|
int echo(char **);
|
|
|
|
int edit1(int *, int);
|
|
|
|
int editor(int *);
|
|
|
|
void edstop(void);
|
|
|
|
int elsecmd(void);
|
|
|
|
int endifcmd(void);
|
|
|
|
int evalcol(int);
|
2016-07-15 15:37:54 +00:00
|
|
|
int execute(char *, int);
|
|
|
|
int exwrite(char *, FILE *, int);
|
2002-03-22 01:33:25 +00:00
|
|
|
void fail(const char *, const char *);
|
|
|
|
int file(char **);
|
1994-05-27 12:33:43 +00:00
|
|
|
struct grouphead *
|
2016-07-15 15:37:54 +00:00
|
|
|
findgroup(char *);
|
2002-03-22 01:33:25 +00:00
|
|
|
void findmail(char *, char *, int);
|
|
|
|
int first(int, int);
|
|
|
|
void fixhead(struct header *, struct name *);
|
|
|
|
void fmt(const char *, struct name *, FILE *, int);
|
|
|
|
int folders(void);
|
2016-07-15 15:37:54 +00:00
|
|
|
int forward(char *, FILE *, char *, int);
|
2002-03-22 01:33:25 +00:00
|
|
|
void free_child(int);
|
2016-07-15 15:37:54 +00:00
|
|
|
int from(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
off_t fsize(FILE *);
|
|
|
|
int getfold(char *, int);
|
2016-07-15 15:37:54 +00:00
|
|
|
int gethfield(FILE *, char *, int, char **);
|
2002-03-22 01:33:25 +00:00
|
|
|
int getmsglist(char *, int *, int);
|
2016-07-15 15:37:54 +00:00
|
|
|
int getrawlist(char *, char **, int);
|
|
|
|
uid_t getuserid(char *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int grabh(struct header *, int);
|
2016-07-15 15:37:54 +00:00
|
|
|
int group(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
void hangup(int);
|
|
|
|
int hash(const char *);
|
|
|
|
void hdrstop(int);
|
2016-07-15 15:37:54 +00:00
|
|
|
int headers(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int help(void);
|
|
|
|
void holdsigs(void);
|
|
|
|
int ifcmd(char **);
|
|
|
|
int igcomp(const void *, const void *);
|
2016-07-15 15:37:54 +00:00
|
|
|
int igfield(void *);
|
|
|
|
int ignore1(char **, struct ignoretab *, const char *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int igshow(struct ignoretab *, const char *);
|
|
|
|
int inc(void *);
|
|
|
|
int incfile(void);
|
|
|
|
void intr(int);
|
2016-07-15 15:37:54 +00:00
|
|
|
int isdate(char *);
|
|
|
|
int isdir(char *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int isfileaddr(char *);
|
2016-07-15 15:37:54 +00:00
|
|
|
int ishead(char *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int isign(const char *, struct ignoretab []);
|
|
|
|
int isprefix(const char *, const char *);
|
|
|
|
void istrncpy(char *, const char *, size_t);
|
2011-12-13 13:32:56 +00:00
|
|
|
const struct cmd *
|
2016-07-15 15:37:54 +00:00
|
|
|
lex(char *);
|
2002-03-22 01:33:25 +00:00
|
|
|
void load(char *);
|
1994-05-27 12:33:43 +00:00
|
|
|
struct var *
|
2002-03-22 01:33:25 +00:00
|
|
|
lookup(const char *);
|
|
|
|
int mail(struct name *,
|
|
|
|
struct name *, struct name *, struct name *, char *, char *);
|
|
|
|
void mail1(struct header *, int);
|
|
|
|
void makemessage(FILE *, int);
|
|
|
|
void mark(int);
|
2016-07-15 15:37:54 +00:00
|
|
|
int markall(char *, int);
|
2002-03-22 01:33:25 +00:00
|
|
|
int matchsender(char *, int);
|
2002-06-25 05:24:30 +00:00
|
|
|
int matchfield(char *, int);
|
2016-07-15 15:37:54 +00:00
|
|
|
int mboxit(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int member(char *, struct ignoretab *);
|
|
|
|
void mesedit(FILE *, int);
|
2016-07-15 15:37:54 +00:00
|
|
|
void mespipe(FILE *, char *);
|
|
|
|
int messize(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int metamess(int, int);
|
2016-07-15 15:37:54 +00:00
|
|
|
int more(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int newfileinfo(int);
|
2016-07-15 15:37:54 +00:00
|
|
|
int next(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int null(int);
|
2016-07-15 15:37:54 +00:00
|
|
|
void parse(char *, struct headline *, char *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int pcmdlist(void);
|
|
|
|
int pdot(void);
|
|
|
|
void prepare_child(sigset_t *, int, int);
|
2016-07-15 15:37:54 +00:00
|
|
|
int preserve(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
void prettyprint(struct name *);
|
2016-07-15 15:37:54 +00:00
|
|
|
void printgroup(char *);
|
2002-03-22 01:33:25 +00:00
|
|
|
void printhead(int);
|
|
|
|
int puthead(struct header *, FILE *, int);
|
|
|
|
int putline(FILE *, char *, int);
|
|
|
|
int pversion(int);
|
|
|
|
void quit(void);
|
|
|
|
int quitcmd(void);
|
|
|
|
int readline(FILE *, char *, int);
|
|
|
|
void register_file(FILE *, int, int);
|
|
|
|
void regret(int);
|
|
|
|
void relsesigs(void);
|
2016-07-15 15:37:54 +00:00
|
|
|
int respond(void *);
|
|
|
|
int retfield(void *);
|
|
|
|
int rexit(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int rm(char *);
|
2016-07-13 16:45:26 +00:00
|
|
|
int run_command(char *, sigset_t *, int, int, ...);
|
|
|
|
int save(void *v);
|
2016-07-15 15:37:54 +00:00
|
|
|
int save1(char *, int, const char *, struct ignoretab *);
|
2002-03-22 01:33:25 +00:00
|
|
|
void savedeadletter(FILE *);
|
2016-07-15 15:37:54 +00:00
|
|
|
int saveigfield(void *);
|
|
|
|
int savemail(char *, FILE *);
|
|
|
|
int saveretfield(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int scan(char **);
|
|
|
|
void scaninit(void);
|
2016-07-15 15:37:54 +00:00
|
|
|
int schdir(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int screensize(void);
|
2016-07-15 15:37:54 +00:00
|
|
|
int scroll(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int sendmessage(struct message *, FILE *, struct ignoretab *, char *);
|
|
|
|
int sendmail(char *);
|
2016-07-15 15:37:54 +00:00
|
|
|
int set(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int setfile(char *);
|
|
|
|
void setmsize(int);
|
|
|
|
void setptr(FILE *, off_t);
|
|
|
|
void setscreensize(void);
|
|
|
|
int shell(char *);
|
|
|
|
void sigchild(int);
|
|
|
|
void sort(char **);
|
|
|
|
int source(char **);
|
|
|
|
void spreserve(void);
|
|
|
|
void sreset(void);
|
2016-07-13 16:45:26 +00:00
|
|
|
int start_command(char *, sigset_t *, int, int, ...);
|
2002-03-22 01:33:25 +00:00
|
|
|
void statusput(struct message *, FILE *, char *);
|
|
|
|
void stop(int);
|
2016-07-15 15:37:54 +00:00
|
|
|
int stouch(void *);
|
|
|
|
int swrite(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
void tinit(void);
|
2016-07-15 15:37:54 +00:00
|
|
|
int top(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
void touch(struct message *);
|
|
|
|
void ttyint(int);
|
|
|
|
void ttystop(int);
|
2016-07-15 15:37:54 +00:00
|
|
|
int type(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int type1(int *, int, int);
|
2016-07-15 15:37:54 +00:00
|
|
|
int undeletecmd(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
void unmark(int);
|
|
|
|
char **unpack(struct name *);
|
2016-07-15 15:37:54 +00:00
|
|
|
int unread(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
void unregister_file(FILE *);
|
2016-07-15 15:37:54 +00:00
|
|
|
int unset(void *);
|
2002-03-22 01:33:25 +00:00
|
|
|
int unstack(void);
|
|
|
|
void vfree(char *);
|
|
|
|
int visual(int *);
|
|
|
|
int wait_child(int);
|
|
|
|
int wait_command(int);
|
|
|
|
int writeback(FILE *);
|
2001-03-25 04:57:05 +00:00
|
|
|
|
|
|
|
extern char *__progname;
|
|
|
|
extern char *tmpdir;
|