Mercurial > hg > xemacs-beta
comparison lib-src/fakemail.c @ 215:1f0dabaa0855 r20-4b6
Import from CVS: tag r20-4b6
author | cvs |
---|---|
date | Mon, 13 Aug 2007 10:07:35 +0200 |
parents | 376386a54a3c |
children | fbbf69b4e8a7 |
comparison
equal
deleted
inserted
replaced
214:c5d88c05e1e9 | 215:1f0dabaa0855 |
---|---|
23 #define NO_SHORTNAMES | 23 #define NO_SHORTNAMES |
24 #include <../src/config.h> | 24 #include <../src/config.h> |
25 | 25 |
26 #if defined (BSD) && !defined (BSD4_1) && !defined (USE_FAKEMAIL) | 26 #if defined (BSD) && !defined (BSD4_1) && !defined (USE_FAKEMAIL) |
27 /* This program isnot used in BSD, so just avoid loader complaints. */ | 27 /* This program isnot used in BSD, so just avoid loader complaints. */ |
28 void | 28 int |
29 main () | 29 main () |
30 { | 30 { |
31 return 0; | |
31 } | 32 } |
32 #elif defined (LINUX) | 33 #elif defined (LINUX) |
33 #include <stdio.h> | 34 #include <stdio.h> |
34 #include <stdlib.h> | 35 #include <stdlib.h> |
35 void | 36 int |
36 main () | 37 main () |
37 { | 38 { |
38 /* Linux /bin/mail, if it exists, is NOT the Unix v7 mail that | 39 /* Linux /bin/mail, if it exists, is NOT the Unix v7 mail that |
39 fakemail depends on! This causes garbled mail. Better to | 40 fakemail depends on! This causes garbled mail. Better to |
40 output an error message. */ | 41 output an error message. */ |
41 fprintf (stderr, "Sorry, fakemail does not work on Linux.\n"); | 42 fprintf (stderr, "Sorry, fakemail does not work on Linux.\n"); |
42 fprintf (stderr, "Make sure you have the sendmail program, and\n"); | 43 fprintf (stderr, "Make sure you have the sendmail program, and\n"); |
43 fprintf (stderr, "set the Lisp variable `sendmail-program' to point\n"); | 44 fprintf (stderr, "set the Lisp variable `sendmail-program' to point\n"); |
44 fprintf (stderr, "to the path of the sendmail binary.\n"); | 45 fprintf (stderr, "to the path of the sendmail binary.\n"); |
45 exit (1); | 46 return 1; |
46 } | 47 } |
47 #else /* not BSD 4.2 (or newer) */ | 48 #else /* not BSD 4.2 (or newer) */ |
48 #ifdef MSDOS | 49 #ifdef MSDOS |
50 int | |
49 main () | 51 main () |
50 { | 52 { |
53 return 0; | |
51 } | 54 } |
52 #else /* not MSDOS */ | 55 #else /* not MSDOS */ |
53 /* This conditional contains all the rest of the file. */ | 56 /* This conditional contains all the rest of the file. */ |
54 | 57 |
55 /* These are defined in config in some versions. */ | 58 /* These are defined in config in some versions. */ |
618 } while (the_header != old); | 621 } while (the_header != old); |
619 put_line (""); | 622 put_line (""); |
620 return; | 623 return; |
621 } | 624 } |
622 | 625 |
623 void | 626 int |
624 main (argc, argv) | 627 main (argc, argv) |
625 int argc; | 628 int argc; |
626 char **argv; | 629 char **argv; |
627 { | 630 { |
628 char *command_line; | 631 char *command_line; |
668 size = fread (buf, 1, BUFLEN, stdin); | 671 size = fread (buf, 1, BUFLEN, stdin); |
669 buf[size] = '\0'; | 672 buf[size] = '\0'; |
670 put_string (buf); | 673 put_string (buf); |
671 } | 674 } |
672 | 675 |
673 exit (close_the_streams ()); | 676 return close_the_streams (); |
674 } | 677 } |
675 | 678 |
676 #endif /* not MSDOS */ | 679 #endif /* not MSDOS */ |
677 #endif /* not BSD 4.2 (or newer) */ | 680 #endif /* not BSD 4.2 (or newer) */ |