home *** CD-ROM | disk | FTP | other *** search
- #include <stdio.h>
- #include <string.h>
- #include "uqwk.h"
-
- #define QWK_MAGIC "Produced by Qmail...Copyright (c) 1987 by Sparkware. All rights Reserved"
-
- InitStuff()
- /*
- * Initialize stuff
- */
- {
- char msg_fname[PATH_LEN];
- int n;
-
- /* Mail, conference, etc. lists */
- mail_list = NULL;
- conf_list = NULL;
- last_conf = NULL;
- act_list = NULL;
- nrc_list = NULL;
-
- /* Message and conference counts */
- msg_cnt = 0;
- conf_cnt = 0;
-
- /* Open MESSAGES.DAT */
- strcpy (msg_fname, home_dir);
- strcat (msg_fname, "/");
- strcat (msg_fname, "messages.dat");
-
- if (NULL == (msg_fd = fopen (msg_fname, "w")))
- {
- fprintf (stderr, "%s: can't open %s\n", progname, msg_fname);
- exit (0);
- }
-
- /* Write magic string to MESSAGES.DAT */
- fprintf (msg_fd, QWK_MAGIC);
- n = 128 - strlen (QWK_MAGIC);
- while (n--) fputc (' ', msg_fd);
- blk_cnt = 2;
- }
-