[BACK]Return to main.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / mail

Diff for /src/usr.bin/mail/main.c between version 1.15 and 1.16

version 1.15, 2001/11/20 20:50:00 version 1.16, 2001/11/21 15:26:39
Line 35 
Line 35 
  */   */
   
 #ifndef lint  #ifndef lint
 static char copyright[] =  static const char copyright[] =
 "@(#) Copyright (c) 1980, 1993\n\  "@(#) Copyright (c) 1980, 1993\n\
         The Regents of the University of California.  All rights reserved.\n";          The Regents of the University of California.  All rights reserved.\n";
 #endif /* not lint */  #endif /* not lint */
   
 #ifndef lint  #ifndef lint
 #if 0  #if 0
 static char sccsid[] = "@(#)main.c      8.2 (Berkeley) 4/20/95";  static const char sccsid[] = "@(#)main.c        8.2 (Berkeley) 4/20/95";
 #else  #else
 static char rcsid[] = "$OpenBSD$";  static const char rcsid[] = "$OpenBSD$";
 #endif  #endif
 #endif /* not lint */  #endif /* not lint */
   
Line 53 
Line 53 
 #include <sys/ioctl.h>  #include <sys/ioctl.h>
 #include "extern.h"  #include "extern.h"
   
 int     main __P((int, char **));  __dead  void    usage(void);
 __dead void usage __P((void));          int     main(int, char **);
   
 /*  /*
  * Mail -- a mail program   * Mail -- a mail program
Line 63 
Line 63 
  */   */
   
 int  int
 main(argc, argv)  main(int argc, char **argv)
         int argc;  
         char *argv[];  
 {  {
         int i;          int i;
         struct name *to, *cc, *bcc, *smopts;          struct name *to, *cc, *bcc, *smopts;
Line 93 
Line 91 
          * first of these users.           * first of these users.
          */           */
         ef = NULL;          ef = NULL;
         to = NIL;          to = NULL;
         cc = NIL;          cc = NULL;
         bcc = NIL;          bcc = NULL;
         smopts = NIL;          smopts = NULL;
         subject = NULL;          subject = NULL;
         while ((i = getopt(argc, argv, "INT:b:c:dfins:u:v")) != -1) {          while ((i = getopt(argc, argv, "INT:b:c:dfins:u:v")) != -1) {
                 switch (i) {                  switch (i) {
Line 200 
Line 198 
         /*          /*
          * Check for inconsistent arguments.           * Check for inconsistent arguments.
          */           */
         if (to == NIL && (subject != NULL || cc != NIL || bcc != NIL))          if (to == NULL && (subject != NULL || cc != NULL || bcc != NULL))
                 errx(1, "You must specify direct recipients with -s, -c, or -b");                  errx(1, "You must specify direct recipients with -s, -c, or -b");
         if (ef != NULL && to != NIL)          if (ef != NULL && to != NULL)
                 errx(1, "Cannot give -f and people to send to");                  errx(1, "Cannot give -f and people to send to");
         /*          /*
          * Block SIGINT except where we install an explicit handler for it.           * Block SIGINT except where we install an explicit handler for it.
Line 266 
Line 264 
  * Width is either 80 or ws_col;   * Width is either 80 or ws_col;
  */   */
 void  void
 setscreensize()  setscreensize(void)
 {  {
         struct termios tbuf;          struct termios tbuf;
         struct winsize ws;          struct winsize ws;
Line 293 
Line 291 
 }  }
   
 __dead void  __dead void
 usage()  usage(void)
 {  {
   
         fprintf(stderr, "usage: %s [-iInv] [-s subject] [-c cc-addr] "          fprintf(stderr, "usage: %s [-iInv] [-s subject] [-c cc-addr] "

Legend:
Removed from v.1.15  
changed lines
  Added in v.1.16