X-Git-Url: http://git.marmaro.de/?p=mmh;a=blobdiff_plain;f=sbr%2Fseq_read.c;h=c18d1dae8a0525ab4ec9c333bb2ab0963d68518f;hp=649a360e41f8500da03777cadccf1969c903f84e;hb=d2da15ecabb03fb2de72863abdf5f21e52fdf329;hpb=1691e80890e5d8ba258c51c214a3e91880e1db2b diff --git a/sbr/seq_read.c b/sbr/seq_read.c index 649a360..c18d1da 100644 --- a/sbr/seq_read.c +++ b/sbr/seq_read.c @@ -4,9 +4,14 @@ * -- initialize sequence information * * $Id$ + * + * This code is Copyright (c) 2002, by the authors of nmh. See the + * COPYRIGHT file in the root directory of the nmh distribution for + * complete copyright information. */ #include +#include /* * static prototypes @@ -18,17 +23,13 @@ static void seq_private (struct msgs *); /* * Get the sequence information for this folder from - * .mh_sequence (or equivalent specified in .mh_profile) + * .mh_sequences (or equivalent specified in .mh_profile) * or context file (for private sequences). */ void seq_read (struct msgs *mp) { - /* sanity check - check that context has been read */ - if (defpath == NULL) - adios (NULL, "oops, context hasn't been read yet"); - /* * Initialize the list of sequence names. Go ahead and * add the "cur" sequence to the list of sequences. @@ -73,7 +74,7 @@ seq_public (struct msgs *mp) /* get filename of sequence file */ snprintf (seqfile, sizeof(seqfile), "%s/%s", mp->foldpath, mh_seq); - if ((fp = fopen (seqfile, "r")) == NULL) + if ((fp = lkfopen (seqfile, "r")) == NULL) return; /* Use m_getfld to scan sequence file */ @@ -111,7 +112,7 @@ seq_public (struct msgs *mp) break; /* break from for loop */ } - fclose (fp); + lkfclose (fp, seqfile); }