Deleted Added
full compact
ctm_smail.c (6081) ctm_smail.c (6290)
1/*
2 * Send a compressed CTM delta to a recipient mailing list by encoding it
3 * in safe ASCII characters, in mailer-friendly chunks, and passing it
4 * to sendmail. The encoding is almost the same as MIME BASE64, and is
5 * protected by a simple checksum.
6 *
7 * Author: Stephen McKay
8 *
9 * NOTICE: This is free software. I hope you get some use from this program.
10 * In return you should think about all the nice people who give away software.
11 * Maybe you should write some free software too.
12 */
13
14#include <stdio.h>
15#include <string.h>
1/*
2 * Send a compressed CTM delta to a recipient mailing list by encoding it
3 * in safe ASCII characters, in mailer-friendly chunks, and passing it
4 * to sendmail. The encoding is almost the same as MIME BASE64, and is
5 * protected by a simple checksum.
6 *
7 * Author: Stephen McKay
8 *
9 * NOTICE: This is free software. I hope you get some use from this program.
10 * In return you should think about all the nice people who give away software.
11 * Maybe you should write some free software too.
12 */
13
14#include <stdio.h>
15#include <string.h>
16#include <unistd.h>
16#include <sys/types.h>
17#include <sys/stat.h>
18#include <errno.h>
19#include <paths.h>
20#include "error.h"
21#include "options.h"
22
23#define DEF_MAX_MSG 64000 /* Default maximum mail msg minus headers. */

--- 6 unchanged lines hidden (view full) ---

30void write_header(FILE *sfp, char *mail_alias, char *delta, int pce,
31 int npieces);
32void write_trailer(FILE *sfp, unsigned sum);
33void apologise(char *delta, off_t ctm_size, long max_ctm_size,
34 char *mail_alias);
35FILE *open_sendmail(void);
36int close_sendmail(FILE *fp);
37
17#include <sys/types.h>
18#include <sys/stat.h>
19#include <errno.h>
20#include <paths.h>
21#include "error.h"
22#include "options.h"
23
24#define DEF_MAX_MSG 64000 /* Default maximum mail msg minus headers. */

--- 6 unchanged lines hidden (view full) ---

31void write_header(FILE *sfp, char *mail_alias, char *delta, int pce,
32 int npieces);
33void write_trailer(FILE *sfp, unsigned sum);
34void apologise(char *delta, off_t ctm_size, long max_ctm_size,
35 char *mail_alias);
36FILE *open_sendmail(void);
37int close_sendmail(FILE *fp);
38
38
39int
39main(int argc, char **argv)
40 {
41 char *delta_file;
42 char *mail_alias;
43 long max_msg_size = DEF_MAX_MSG;
44 long max_ctm_size = 0;
45 char *log_file = NULL;
46 struct stat sb;

--- 278 unchanged lines hidden ---
40main(int argc, char **argv)
41 {
42 char *delta_file;
43 char *mail_alias;
44 long max_msg_size = DEF_MAX_MSG;
45 long max_ctm_size = 0;
46 char *log_file = NULL;
47 struct stat sb;

--- 278 unchanged lines hidden ---